New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

bbox-fns

Package Overview
Dependencies
Maintainers
1
Versions
24
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

bbox-fns - npm Package Compare versions

Comparing version 0.15.0 to 0.16.0

split.js

2

index.js

@@ -23,2 +23,3 @@ "use_strict";

const scale = require("./scale.js");
const split = require("./split.js");
const validate = require("./validate.js");

@@ -49,2 +50,3 @@ const preciseValidate = require("./precise/validate.js");

scale,
split,
validate,

@@ -51,0 +53,0 @@ preciseValidate,

5

package.json
{
"name": "bbox-fns",
"version": "0.15.0",
"version": "0.16.0",
"description": "Light-weight JavaScript Bounding Box Utility Functions",
"main": "index.js",
"main": "./index.js",
"files": [

@@ -31,2 +31,3 @@ "index.js",

"precise/validate.js",
"split.js",
"union.js",

@@ -33,0 +34,0 @@ "validate.js"

@@ -14,2 +14,3 @@ # bbox-fns: work in progress

- [bboxPoint](#bboxPoint)
- [bboxSize](#bboxSize)
- [booleanContains](#booleanContains)

@@ -28,2 +29,3 @@ - [booleanContainsPoint](#booleanContainsPoint)

- [scale](#scale)
- [split](#split)
- [union](#union)

@@ -273,2 +275,24 @@ - [validate](#validate)

### split
Split bounding box that crosses given x or y boundaries. For example, split a bbox that crosses the antimeridian into two bounding boxes.
```js
import split from "bbox-fns/split.js";
// split across the antimeridian
split([-200, -90, 160, 90], { x: [-180, 180] })
[
[-200, -90, -180, 90], // overflow, left of antimeridian
[-180, -90, 160, 90] // right of antimeridian
]
// split across the antimeridian and the poles
split([-200, -90, 160, 100], { x: [-180, 180], y: [-90, 90] })
[
[-200,-90,-180,90],
[-200,90,-180,100],
[-180,-90,160,90],
[-180,90,160,100]
]
```
### reproject

@@ -345,2 +369,2 @@ Reproject a bounding box using the given reprojection function

["0", "2.25", "16.666...", "50"]
```
```
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc