Reputation: 3
Is this a problem? The map works but I don't know if the canceled requests are a problem I should address. The console is showing the following when I open a map with a single line on it.Console log
let map;
async function initMap() {
const position = { lat: 32.633, lng: -97.165 };
const { Map } = await google.maps.importLibrary("maps");
const { AdvancedMarkerElement } = await google.maps.importLibrary("marker");
map = new google.maps.Map(document.getElementById('map'), {
center: position,
zoom: 5
});
//-------------------------------------------------
let path = [
{ lat: 32.6998, lng: -97.1250 }, // Arlington, TX
{ lat: 29.7860, lng: -95.3885 }, // Houston, TX
];
let polyline = new google.maps.Polyline({
path: path,
strokeColor: "#FF0000",
strokeOpacity: 1.0,
strokeWeight: 4,
map: map,
});
//-----------------------------------------------------
}
initMap();
Upvotes: 0
Views: 9