1.完成工具和数据准备

地图数据的准备

地图选择器​datav.aliyun.com

http://datav.aliyun.com/tools/atlas/#&lat=31.840232667909365&lng=104.2822265625&zoom=4

进入这个网站找到你需要的省份数据,以四川省为例:

https://geo.datav.aliyun.com/areas_v2/bound/100000.json 

下载 JSON API(包含子区域)或直接打开网站复制里面的JSON数据,可以直接把四川省的JSON数据复制到项目中; 

到这里数据就准备完成了!

安装Echarts 并引入

npm install echarts --save

// main.js  import echarts from 'echarts'Vue.prototype.echarts = echarts 

// 使用  this.echarts 

2.开始构建地图

乡镇数据

https://giser.xyz/demo/03-Dist-AMap/index.html 

相关文章:

  • 2021-11-13
  • 2022-12-23
  • 2021-09-09
  • 2021-09-05
  • 2022-12-23
  • 2021-06-28
猜你喜欢
  • 2022-12-23
  • 2021-07-24
  • 2021-04-30
  • 2021-10-12
  • 2022-01-23
  • 2021-09-22
  • 2022-02-26
相关资源
相似解决方案