You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, please describe the issue. What is the expected behavior and what happens instead? If you are seeing an error message in the JavaScript console, share that as well.
Operating system
ubuntu 22.04
Browser Version
Chrome 104.0.5112.101 (oficial) 64 bits
How severe is the bug?
moderate
Bug description
function initMap() {
const myLatlng = { lat: -25.363, lng: 131.044 };
const map = new google.maps.Map(document.getElementById("map")!, {
zoom: 4,
center: myLatlng,
});
// Create the initial InfoWindow.
let infoWindow = new google.maps.InfoWindow({
content: "Click the map to get Lat/Lng!",
position: myLatlng,
});
infoWindow.open(map);
// Configure the click listener.
map.addListener("click", (mapsMouseEvent) => {
// Close the current InfoWindow.
infoWindow.close();
});
}
declare global {
interface Window {
initMap: () => void;
}
}
window.initMap = initMap;
export {};
Steps to reproduce
Just run.
Console log output
The text was updated successfully, but these errors were encountered: