Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@turf/center

Package Overview
Dependencies
Maintainers
4
Versions
61
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@turf/center - npm Package Compare versions

Comparing version 4.5.2 to 4.6.0

34

index.js

@@ -12,29 +12,7 @@ var bbox = require('@turf/bbox');

* @example
* var features = {
* "type": "FeatureCollection",
* "features": [
* {
* "type": "Feature",
* "properties": {},
* "geometry": {
* "type": "Point",
* "coordinates": [-97.522259, 35.4691]
* }
* }, {
* "type": "Feature",
* "properties": {},
* "geometry": {
* "type": "Point",
* "coordinates": [-97.502754, 35.463455]
* }
* }, {
* "type": "Feature",
* "properties": {},
* "geometry": {
* "type": "Point",
* "coordinates": [-97.508269, 35.463245]
* }
* }
* ]
* };
* var features = turf.featureCollection([
* turf.point( [-97.522259, 35.4691]),
* turf.point( [-97.502754, 35.463455]),
* turf.point( [-97.508269, 35.463245])
* ]);
*

@@ -44,5 +22,5 @@ * var center = turf.center(features);

* //addToMap
* var addToMap = [features, center]
* center.properties['marker-size'] = 'large';
* center.properties['marker-color'] = '#000';
* var addToMap = [features, center]
*/

@@ -49,0 +27,0 @@ module.exports = function (geojson, properties) {

12

package.json
{
"name": "@turf/center",
"version": "4.5.2",
"version": "4.6.0",
"description": "turf center module",

@@ -34,13 +34,13 @@ "main": "index.js",

"devDependencies": {
"@turf/meta": "^4.5.2",
"@turf/meta": "^4.6.0",
"benchmark": "^2.1.4",
"glob": "^7.1.2",
"load-json-file": "^2.0.0",
"load-json-file": "2.0.0",
"tape": "^4.6.3",
"write-json-file": "^2.2.0"
"write-json-file": "2.2.0"
},
"dependencies": {
"@turf/bbox": "^4.5.2",
"@turf/helpers": "^4.5.2"
"@turf/bbox": "^4.6.0",
"@turf/helpers": "^4.6.0"
}
}

@@ -15,29 +15,7 @@ # @turf/center

```javascript
var features = {
"type": "FeatureCollection",
"features": [
{
"type": "Feature",
"properties": {},
"geometry": {
"type": "Point",
"coordinates": [-97.522259, 35.4691]
}
}, {
"type": "Feature",
"properties": {},
"geometry": {
"type": "Point",
"coordinates": [-97.502754, 35.463455]
}
}, {
"type": "Feature",
"properties": {},
"geometry": {
"type": "Point",
"coordinates": [-97.508269, 35.463245]
}
}
]
};
var features = turf.featureCollection([
turf.point( [-97.522259, 35.4691]),
turf.point( [-97.502754, 35.463455]),
turf.point( [-97.508269, 35.463245])
]);

@@ -47,5 +25,5 @@ var center = turf.center(features);

//addToMap
var addToMap = [features, center]
center.properties['marker-size'] = 'large';
center.properties['marker-color'] = '#000';
var addToMap = [features, center]
```

@@ -52,0 +30,0 @@

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