3.0.12 • Published 8 years ago
turf-envelope v3.0.12
turf-envelope
turf envelope module
turf.envelope(fc)
Takes a Feature or FeatureCollection and returns a rectangular Polygon feature that encompasses all vertices.
Parameters
parameter | type | description |
---|---|---|
fc | FeatureCollection | a FeatureCollection of any type |
Example
var fc = turf.featurecollection([
turf.point([-75.343, 39.984], {name: 'Location A'}),
turf.point([-75.833, 39.284], {name: 'Location B'}),
turf.point([-75.534, 39.123], {name: 'Location C'})
]);
var enveloped = turf.envelope(fc);
var result = turf.featurecollection(
fc.features.concat(enveloped));
//=result
Installation
Requires nodejs.
$ npm install turf-envelope
Tests
$ npm test
3.0.12
8 years ago
3.0.10
8 years ago
3.0.7-canary.ae89c8b3
8 years ago
3.0.5
8 years ago
3.0.1
8 years ago
3.0.0-canary.7879bf6c
8 years ago
3.0.0-canary.2f5f7167
8 years ago
1.0.2
9 years ago
1.0.1
9 years ago
1.0.0
9 years ago
0.1.1
10 years ago
0.1.0
10 years ago