HBuilderX版本号:3.1.7
基础库版本号: 2.16.0
以下是测试的.vue文件:
<template>
<view class="pscontainer">
<map style="width: 100%; height: 300px;"
:markers="covers"
:latitude="latitude"
:longitude="longitude"
:enable-zoom="true"
:include-points="covers">
</map>
</view>
</template>
<script>
export default {
data() {
return {
title: 'map',
latitude: 39.909,
longitude: 116.39742,
covers: [{
id: 0,
latitude: 39.909,
longitude: 116.39742,
iconPath: '../../static/sandcastle.png'
}, {
id: 1,
latitude: 39.90,
longitude: 116.39,
iconPath: '../../static/sandcastle.png'
}],
includePoints: []
}
},
methods:{
loaded() {
}
},
}
</script>
<style lang="scss" scoped>
.pscontainer {
width: 100%;
height: 100%;
}
</style>
0 个回复