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

@turf/line-intersect

Package Overview
Dependencies
Maintainers
4
Versions
50
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@turf/line-intersect - npm Package Compare versions

Comparing version 3.11.6 to 3.12.2

17

index.js

@@ -161,3 +161,3 @@ var rbush = require('rbush');

case 'MultiLineString':
multiFeature = flatten(multiFeature);
multiFeature = flattenMultiLineString(multiFeature);
break;

@@ -197,2 +197,17 @@ case 'Polygon':

/**
* Flatten MultiLineString
*
* @private
* @param {Feature<MultiLineString>} multiLineString GeoJSON Feature
* @returns {FeatureCollection<LineString>} Feature Collection
*/
function flattenMultiLineString(multiLineString) {
var lines = [];
multiLineString.geometry.coordinates.forEach(function (coordinates) {
lines.push(helpers.lineString(coordinates));
});
return helpers.featureCollection(lines);
}
/**
* Converts Polygon(s) to FeatureCollection LineStrings

@@ -199,0 +214,0 @@ *

4

package.json
{
"name": "@turf/line-intersect",
"version": "3.11.6",
"version": "3.12.2",
"description": "Takes any LineString or Polygon GeoJSON and returns the intersecting point(s).",

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

"@turf/bbox-polygon": "^3.10.5",
"@turf/flatten": "^3.10.5",
"@turf/flatten": "^3.12.2",
"@turf/helpers": "^3.10.5",

@@ -37,0 +37,0 @@ "@turf/meta": "^3.10.5",

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