$ npm install @antv/l7-district
Install dependencies,
$ yarn install
Start the dev server,
$ yarn run start
Build documentation,
$ yarn run docs:build
Build library via father-build
,
$ yarn run build
import { setDataConfig } from '@antv/l7-district';
setDataConfig({
country: {
CHN: {
1: {
// 设置省级地图
fill: {
type: 'pbf', // 支持pbf 和 geojson pbf 进行了数据压缩,减少数据量
url:
'https://gw.alipayobjects.com/os/bmw-prod/47af6305-062e-454f-9e8a-55e0808b2b7a.bin',
},
},
},
},
});
可以将 GeoJSON 转成 Pbf
© 2010 - cnpmjs.org x YWFE | Home | YWFE