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
285 stars 56 forks source link

GoogleMap drag method can not get position #182

Closed rain-sc closed 6 months ago

rain-sc commented 11 months ago
  <GoogleMap
        ref="mapRef"
        api-key="AIzaSyBxF48DO6GpNH2yrM0XpzwjIZH7HoQQyXU"
        style="width: 100%;height: 500px"
        :center="center"
        :zoom="15"
        @dragend="dragPosition($event)"
      >
 <Marker
          v-for="(item, index) in position"
          :key="index"
          :options="{
            position {item.lng, item.lat}
          }"
          animation="0.5"
        />
      </GoogleMap>

function dragPosition(event){
console.log(event) // output is undefined
}