@turf/boolean-clockwise
Advanced tools
Comparing version 5.0.4 to 5.1.0
@@ -7,3 +7,3 @@ import { getCoords } from '@turf/invariant'; | ||
* @name booleanClockwise | ||
* @param {Geometry|Feature<LineString>|Array<Array<number>>} line to be evaluated | ||
* @param {Feature<LineString>} line to be evaluated | ||
* @returns {boolean} true/false | ||
@@ -10,0 +10,0 @@ * @example |
@@ -9,3 +9,3 @@ 'use strict'; | ||
* @name booleanClockwise | ||
* @param {Geometry|Feature<LineString>|Array<Array<number>>} line to be evaluated | ||
* @param {Feature<LineString>} line to be evaluated | ||
* @returns {boolean} true/false | ||
@@ -23,5 +23,5 @@ * @example | ||
// validation | ||
if (!line) throw new Error('line is required'); | ||
if (!line) { throw new Error('line is required'); } | ||
var type = (line.geometry) ? line.geometry.type : line.type; | ||
if (!Array.isArray(line) && type !== 'LineString') throw new Error('geometry must be a LineString'); | ||
if (!Array.isArray(line) && type !== 'LineString') { throw new Error('geometry must be a LineString'); } | ||
@@ -28,0 +28,0 @@ var ring = invariant.getCoords(line); |
{ | ||
"name": "@turf/boolean-clockwise", | ||
"version": "5.0.4", | ||
"version": "5.1.0", | ||
"description": "turf boolean-clockwise module", | ||
"main": "main", | ||
"module": "index", | ||
"jsnext:main": "index", | ||
"main": "main.js", | ||
"module": "main.mjs", | ||
"types": "index.d.ts", | ||
@@ -12,3 +11,4 @@ "files": [ | ||
"index.d.ts", | ||
"main.js" | ||
"main.js", | ||
"main.mjs" | ||
], | ||
@@ -18,3 +18,4 @@ "scripts": { | ||
"test": "node -r @std/esm test.js", | ||
"bench": "node -r @std/esm bench.js" | ||
"bench": "node -r @std/esm bench.js", | ||
"docs": "node ../../scripts/generate-readmes" | ||
}, | ||
@@ -48,7 +49,8 @@ "repository": { | ||
"rollup": "*", | ||
"rollup-plugin-buble": "*", | ||
"tape": "*" | ||
}, | ||
"dependencies": { | ||
"@turf/helpers": "^5.0.4", | ||
"@turf/invariant": "^5.0.4" | ||
"@turf/helpers": "^5.1.0", | ||
"@turf/invariant": "^5.1.0" | ||
}, | ||
@@ -55,0 +57,0 @@ "@std/esm": { |
@@ -11,3 +11,3 @@ # @turf/boolean-clockwise | ||
- `line` **([Geometry](http://geojson.org/geojson-spec.html#geometry) \| [Feature](http://geojson.org/geojson-spec.html#feature-objects)<[LineString](http://geojson.org/geojson-spec.html#linestring)> | [Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[Array](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array)<[number](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number)>>)** to be evaluated | ||
- `line` **[Feature](https://tools.ietf.org/html/rfc7946#section-3.2)<[LineString](https://tools.ietf.org/html/rfc7946#section-3.1.4)>** to be evaluated | ||
@@ -14,0 +14,0 @@ **Examples** |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
7426
7
111
7
Updated@turf/helpers@^5.1.0
Updated@turf/invariant@^5.1.0