我正在嘗試使用谷歌地圖和插件https://www.npmjs.com/package/vue2-google-maps構(gòu)建一個 vue 谷歌地圖組件。我已經(jīng)使用 npm 安裝了插件,并且當我的 googleMap.vue 組件開始工作時:<template> <div> <v-container row fill-height justify-center style="max-width: 1200px" > <v-flex><span style="display:block"> <GmapMap :center="{lat:10, lng:10}" :zoom="7" map-type-id="terrain" style="width: 500px; height: 300px"> <!-- <GmapMarker :key="index" v-for="(m, index) in markers" :position="m.position" :clickable="true" :draggable="true" @click="center=m.position" /> --></GmapMap></span> </v-flex> </v-container> </div></template><script>var latitute = 1030.08674842var longitude = -97.29304982export default { // name:'myMap' latitute, longitude}</script><style></style>它顯示了尼日利亞的地圖。我有一個地圖,我想用這個組件顯示:https://www.google.com/maps/@30.086753,-97.2952385,17z我在上面取經(jīng)緯度并替換進去,所以它看起來像屏幕截圖,有控件但沒有地圖: :center="{lat:1030.08674842, lng:-97.29304982}"我檢查了我的控制臺:https://console.cloud.google.com/google/maps-apis/apis/maps-backend.googleapis.com/metrics今天所有的請求都有 200 個狀態(tài)碼我究竟做錯了什么?
重置緯度和經(jīng)度不會創(chuàng)建地圖
富國滬深
2021-06-18 14:57:22