xkjyeah / vue-google-maps

Google maps component for vue with 2-way data binding
https://xkjyeah.github.io/vue-google-maps/
1.88k stars 474 forks source link

Fetch lng and lat from API #681

Closed engmagdy87 closed 4 years ago

engmagdy87 commented 4 years ago

hi I fetch lng and lat from API

<div class="col-lg-4" v-if="mapPoints!==null">
<GmapMap
  :center="{lat:Number(mapPoints.lat), lng:Number(mapPoints.lng)}"
  :zoom="7"
  map-type-id="terrain"
  style="width: 100%; height: 200px"
/>
</div>

but it seems that GmapMap component rendered even v-if value is still false and before response consumed from api

I follow this solution but the map still rendered