Answers for "invalidvalueerror: setcenter: not a latlng or latlngliteral with finite coordinates: in property lat: not a number in angular 11"

0

setCenter: not a LatLng or LatLngLiteral with finite coordinates: in property lat: not a number

//The error comes because you pass the value as string:
var lat = document.getElementById('lat').value;

//you need to set it as float:
var lat = parseFloat(document.getElementById('lat').value);
Posted by: Guest on January-26-2021

Code answers related to "invalidvalueerror: setcenter: not a latlng or latlngliteral with finite coordinates: in property lat: not a number in angular 11"

Code answers related to "Javascript"

Browse Popular Code Answers by Language