inocan-group / vue3-google-map

A set of composable components for easy use of Google Maps in your Vue 3 projects.
https://vue3-google-map.com
MIT License
295 stars 60 forks source link

update changed zoom value #276

Closed hdrodel closed 3 months ago

hdrodel commented 3 months ago

Is it possible get the updated zoom value ? does the component emit it?

I have a use case where i want to display certain markers based on how far it's zoomed in. I wanted to use v-if based on zoom value but changing the zoom does not update the zoom parameter. Is there a way to do this?

Edit: I've tried this:

<GoogleMap 
    api-key: "<key>"
    :zoom="zoom"
   @update:zoom="zoom=$event"
/>

but it does not work