ngx-echarts
ngx-echarts copied to clipboard
it does not support geo?
I imported map and
"node_modules/echarts/map/js/china.js", "node_modules/echarts/dist/extension/bmap.js"
Both in file angular-cli and tsconfig
with config:
geo: { map: 'china', label: { emphasis: { show: false } }, roam: true, itemStyle: { normal: { areaColor: '#323c48', borderColor: '#111' }, emphasis: { areaColor: '#2a333d' } } }
But it's not working.
Please give help.
Thanks
@StevenWung
geo is supported. I think the map data is not registered properly in your case.
You can load "node_modules/echarts/map/json/china.json"
and register it manually by calling echarts.registerMap("china", chinaJSON)
. This should be done before you use geo: { map: 'china', ... }
.
You can refer to my demo: https://xieziyu.github.io/ngx-echarts/#/demo/map/hongkong-pd
@xieziyu Thanks another question: does it support this kind of map? http://www.echartsjs.com/examples/editor.html?c=map-polygon
@StevenWung Yes, it does. You need import baidu map library.
Why does the configuration bmap not work? in angular7.
@StevenWung 是的,确实如此。你需要导入百度地图库。
@xieziyu Has geo been removed from the latest version?