Baidu Map components for Vue 2.x
Baidu Map components for Vue 2.x
https://dafrok.github.io/vue-baidu-map
npm i --save vue-baidu-map
import Vue from 'vue'
import BaiduMap from 'vue-baidu-map'
Vue.use(BaiduMap, {
/* Visit http://lbsyun.baidu.com/apiconsole/key for details about app key. */
ak: 'YOUR_APP_KEY'
})
<template>
<baidu-map class="map">
</baidu-map>
</template>
<style>
/* The container of BaiduMap must be set width & height. */
.map {
width: 100%;
height: 300px;
}
</style>
Copyright © 2016-present, Dafrok [email protected]