Giter VIP home page Giter VIP logo

baidu-map's People

Contributors

lunnlew avatar squidcatx avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

baidu-map's Issues

局部导入-地图标注失败

问题描述

在局部导入的情况下,地图标注失败

代码

<template>
    <baidu-map
        class="map"
        ref="map"
        :apiKey="'z7ngXdkrDCY1oFfaFLxyvL6UtiXu0f88'"
        :center="point"
        :enableMapClick="true"
        :enableWheelZoom="true"
        :mapType="BMapGLConstant.MapTypeId.BMAP_NORMAL_MAP"
    >
        <bm-marker :point="point" :show="isShowMaker">
            <bm-marker-icon :size="[23, 25]" :anchor="[10, 15]" :imageOffset="[0, 0]"></bm-marker-icon>
        </bm-marker>
    </baidu-map>
</template>

<script setup>
import { BaiduMap, BMapGLConstant } from "baidu-map-vue3";
import { ref } from "vue";

const point = ref({
    lng: 116.403963,
    lat: 39.915119,
});
const isShowMaker = ref(true);
const isShowLabel = ref(true);
</script>

<style>
.map {
    width: 100%;
    height: 500px;
}
</style>

问题 Demo 链接

baidumap-localimport-demo.zip

CORS

您好 跨域怎么配置呢

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.