【GIS】Vue esri-leaflet

1、npm install esri-leaflet --save

2、引入包

import Leaflet from "leaflet";
 
var esri = require("esri-leaflet");
 

3、添加底图

esri.basemapLayer("Topographic").addTo(this.map);

 

4、添加动态服务
 
esri.dynamicMapLayer({
url:"https://services.arcgisonline.com/arcgis/rest/services/Specialty/Soil_Survey_Map/MapServer",
opacity: 0.7
})
.addTo(this.map);

 

posted @ 2019-01-27 17:43  咸鱼翻身  阅读(1453)  评论(0编辑  收藏  举报