【文件属性】:
文件名称:geojson-bounding-box:有效计算 GeoJSON 的边界框
文件大小:90KB
文件格式:ZIP
更新时间:2021-08-03 11:30:36
algorithm geojson geospatial gis box
geojson-边界框
使用生成器有效地计算 GeoJSON 的边界框以遍历其坐标。
入门
安装
npm install --save geojson-bounding-box
例子
const toBBox = require ( 'geojson-bounding-box' ) ;
const line = {
"type" : "Feature" ,
"geometry" : {
"type" : "LineString" ,
"coordinates" : [
[ 0 , 1 ] , [ 1 , 2 ] , [ 2 , 1 ]
]
} ,
"properties" : { }
} ;
const bbox = toBBox ( line ) ;
// = [0, 1, 2, 2]
建造
在本地构建和测试库:
npm inst
【文件预览】:
geojson-bounding-box-master
----.eslintrc.json(277B)
----.gitignore(92B)
----package.json(2KB)
----package-lock.json(377KB)
----license.txt(1KB)
----.travis.yml(120B)
----index.js(2KB)
----rollup.config.js(651B)
----readme.md(1KB)
----test()
--------test.js(2KB)