Skip to content
This repository has been archived by the owner on Jul 5, 2023. It is now read-only.

How to use AMap api in React project? #9

Open
szu-bee opened this issue Dec 18, 2018 · 1 comment
Open

How to use AMap api in React project? #9

szu-bee opened this issue Dec 18, 2018 · 1 comment

Comments

@szu-bee
Copy link

szu-bee commented Dec 18, 2018

How can I apply following code for my react project? Where is AMap from?

let map = echart.getModel().getComponent('amap').getAMap();
   
AMap.plugin(["AMap.ControlBar"], function () {
  let bar = new AMap.ControlBar();   
  map.addControl(bar);
});
@billy-poon
Copy link
Owner

AMap是来自高德地图的JS SDK,参考:https://lbs.amap.com/api/javascript-api/summary/

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants