// 地图控制器
<template lang="pug">
.main
#map.container
.pane(@click="save") 导出
</template>
<script>
import "maptalks/dist/maptalks.css";
import * as maptalks from "maptalks";
export default {
data() {
return {
map: "",
};
},
mounted() {
this.map = new maptalks.Map("map", {
center: [120.20377025390627, 30.19386063195693], //中心坐标位置
zoom: 14,
pitch: 45, //倾斜角度
attribution: true,
zoomControl: true, // 添加缩放等级控制器
scaleControl: true, // 显示地图标尺
overviewControl: true, // add overview control
baseLayer: new maptalks.TileLayer("base", {
urlTemplate:
"https://{s}.bas
maptalks地图控制器、限制拖动区域、marker标记、导出示例
最新推荐文章于 2023-02-15 11:42:09 发布
![](https://img-home.csdnimg.cn/images/20240711042549.png)