Package Exports
- turf-grid
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (turf-grid) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
turf-grid
turf grid module
turf.grid(extent, depth)
Takes a bounding box and a cell depth and returns a FeatureCollection of Point features in a grid.
Parameters
| parameter | type | description |
|---|---|---|
extent |
Array. |
extent in [minX, minY, maxX, maxY] order |
depth |
Number | how many cells to output |
Example
var extent = [-70.823364, -33.553984, -70.473175, -33.302986];
var depth = 10;
var grid = turf.grid(extent, depth);
//=gridInstallation
Requires nodejs.
$ npm install turf-gridTests
$ npm test