vue-google-maps
vue-google-maps copied to clipboard
Ground / Custom Overlays
Is your feature request related to a problem? Please describe. It would be nice to have the possibility to use ground / custom overlays.
Describe the solution you'd like If we can create a new map object we can attach the overlay to that.
Describe alternatives you've considered No alternative I think
Additional context Here is what I want to use: https://developers.google.com/maps/documentation/javascript/groundoverlays?hl=en
I found out how to do it. mapRef is the ref of the GMapMap
onMounted(() => {
mapRef.value
.$gmapApiPromiseLazy()
.then(() => {
const groundOverlay = new google.maps.GroundOverlay(
'https://storage.googleapis.com/geo-devrel-public-buckets/newark_nj_1922-661x516.jpeg',
{
east: 17.703271508054467,
north: 46.573320157456465,
south: 46.56439415563869,
west: 17.687189407348647,
}
)
groundOverlay.setMap(mapRef.value?.$mapObject)
})
.catch(err => console.error(err))
})