I try to circumscribe the whole map in a rectangle but the points shift up and down too much! How do I deal with it?
const map = new google.maps.Map(document.getElementById("map"), { zoom: 5, center: { lat: 24.886, lng: -70.268 }, mapTypeId: "terrain" });
const rectCoordinates = [
{ lat: 90, lng: -180 }, { lat: 90, lng: 180 }, { lat: -90, lng: 180 }, { lat: -90, lng: -180 },
];
const rect = new google.maps.Polygon({
paths: rectCoordinates,
strokeColor: "#FF0000",
strokeOpacity: 0.8,
strokeWeight: 2
});
rect.setMap(map);
