Socket
Socket
Sign inDemoInstall

turf

Package Overview
Dependencies
Maintainers
1
Versions
122
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

turf - npm Package Compare versions

Comparing version 0.0.106 to 0.0.107

test/testIn/countries.geojson

5

lib/union.js

@@ -11,2 +11,7 @@ // look here for help http://svn.osgeo.org/grass/grass/branches/releasebranch_6_4/vector/v.overlay/main.c

module.exports = function(poly1, poly2, done){
console.log('================')
console.log('prop1: ', poly1.properties)
console.log('prop2: ', poly2.properties)
console.log('poly1: ',poly1.geometry.type)
console.log('poly2: ',poly2.geometry.type)
var reader = new jsts.io.GeoJSONReader()

@@ -13,0 +18,0 @@ var a = reader.read(JSON.stringify(poly1.geometry))

2

package.json
{
"name": "turf",
"version": "0.0.106",
"version": "0.0.107",
"description": "a node.js library for performing geospatial operations with geojson",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -16,2 +16,22 @@ var t = require('../index'),

})
it('should take a set of polygons sharing a border and merge them into a single polygon', function(done){
t.load('../test/testIn/mergeIn2.geojson', function(err, polygons){
t.merge(polygons, function(err, mergeOut){
if(err) throw err
fs.writeFileSync('./testOut/merge2.geojson', JSON.stringify(mergeOut))
mergeOut.should.be.ok
done()
})
})
})
xit('should take a set of polygons for all countries and create a set of continents', function(done){
t.load('../test/testIn/countries.geojson', function(err, polygons){
t.merge(polygons, function(err, mergeOut){
if(err) throw err
fs.writeFileSync('./testOut/world.geojson', JSON.stringify(mergeOut))
mergeOut.should.be.ok
done()
})
})
})
})

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

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