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

@turf/collect

Package Overview
Dependencies
Maintainers
7
Versions
62
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@turf/collect - npm Package Compare versions

Comparing version 6.5.0 to 7.0.0-alpha.0

2

dist/es/index.js

@@ -35,3 +35,3 @@ import turfbbox from "@turf/bbox";

function collect(polygons, points, inProperty, outProperty) {
var rtree = rbush(6);
var rtree = new rbush(6);
var treeItems = points.features.map(function (item) {

@@ -38,0 +38,0 @@ var _a;

@@ -1,2 +0,2 @@

import { FeatureCollection, Polygon, Point } from "@turf/helpers";
import { FeatureCollection, Polygon, Point } from "geojson";
/**

@@ -3,0 +3,0 @@ * Merges a specified property from a FeatureCollection of points into a

"use strict";
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
var bbox_1 = __importDefault(require("@turf/bbox"));
var boolean_point_in_polygon_1 = __importDefault(require("@turf/boolean-point-in-polygon"));
var rbush_1 = __importDefault(require("rbush"));
const tslib_1 = require("tslib");
const bbox_1 = tslib_1.__importDefault(require("@turf/bbox"));
const boolean_point_in_polygon_1 = tslib_1.__importDefault(require("@turf/boolean-point-in-polygon"));
const rbush_1 = tslib_1.__importDefault(require("rbush"));
/**

@@ -40,3 +38,3 @@ * Merges a specified property from a FeatureCollection of points into a

function collect(polygons, points, inProperty, outProperty) {
var rtree = rbush_1.default(6);
var rtree = new rbush_1.default(6);
var treeItems = points.features.map(function (item) {

@@ -43,0 +41,0 @@ var _a;

{
"name": "@turf/collect",
"version": "6.5.0",
"version": "7.0.0-alpha.0",
"description": "turf collect module",

@@ -54,3 +54,3 @@ "author": "Turf Authors",

"devDependencies": {
"@types/rbush": "^2.0.3",
"@types/rbush": "^3.0.0",
"@types/tape": "*",

@@ -65,8 +65,9 @@ "benchmark": "*",

"dependencies": {
"@turf/bbox": "^6.5.0",
"@turf/boolean-point-in-polygon": "^6.5.0",
"@turf/helpers": "^6.5.0",
"rbush": "2.x"
"@turf/bbox": "^7.0.0-alpha.0",
"@turf/boolean-point-in-polygon": "^7.0.0-alpha.0",
"@turf/helpers": "^7.0.0-alpha.0",
"rbush": "^3.0.1",
"tslib": "^2.3.0"
},
"gitHead": "5375941072b90d489389db22b43bfe809d5e451e"
"gitHead": "0edc4c491b999e5ace770a61e1cf549f7c004189"
}

@@ -13,10 +13,10 @@ # @turf/collect

**Parameters**
### Parameters
- `polygons` **[FeatureCollection][1]<[Polygon][2]>** polygons with values on which to aggregate
- `points` **[FeatureCollection][1]<[Point][3]>** points to be aggregated
- `inProperty` **[string][4]** property to be nested from
- `outProperty` **[string][4]** property to be nested into
* `polygons` **[FeatureCollection][1]<[Polygon][2]>** polygons with values on which to aggregate
* `points` **[FeatureCollection][1]<[Point][3]>** points to be aggregated
* `inProperty` **[string][4]** property to be nested from
* `outProperty` **[string][4]** property to be nested into
**Examples**
### Examples

@@ -41,3 +41,3 @@ ```javascript

Returns **[FeatureCollection][1]&lt;[Polygon][2]>** polygons with properties listed based on `outField`
Returns **[FeatureCollection][1]<[Polygon][2]>** polygons with properties listed based on `outField`

@@ -44,0 +44,0 @@ [1]: https://tools.ietf.org/html/rfc7946#section-3.3

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