Giter VIP home page Giter VIP logo

Comments (3)

lixy01 avatar lixy01 commented on September 18, 2024

1.项目先引入 原生 cesium 1.89.0版本 2.再次引入 cesium-map 3.项目采用局部注册 4.代码大概如下 import * as Cesium from 'cesium/Cesium' import 'cesium/Widgets/widgets.css' require('@dvgis/cesium-map') 报 Cesium is not defined

同样的问题 你解决了么

from cesium-map.

apgk avatar apgk commented on September 18, 2024
  1. 项目先引入铯 1.89.0 2. 引入铯-map 3. 项目采用以下版本报告 4. 代码概略如下import * as Cesium from 'cesium/Cesium' import 'cesium/Widgets/widgets.css' require('@dvgis/cesium-map'): 铯未定义

你的问题解决了么么哒
两种解决方式

import * as Cesium from 'cesium/Cesium'
window.Cesium =Cesium
require('@dvgis/cesium-map')

2.下载代码,更改其中涉及到的cesium 引用
为import * as Cesium from 'cesium/Cesium'
注意保留作者信息
其余我就没想到怎么解决了

from cesium-map.

cavencj avatar cavencj commented on September 18, 2024

global.Cesium = require(''cesium/Cesium'')

from cesium-map.

Related Issues (15)

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.