Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
window.navigator.geolocation.getCurrentPosition(point => {
this.centerPoint = gcoord.transform([point.coords.longitude, point.coords.latitude], gcoord.WGS84, gcoord.AMap);
}, error => {
this.msg.add(error.message);