1.0.60 • Published 1 year ago
@even_jie/jesium v1.0.60
Jesium
概述:利用原生cesium封装一些常用功能,帮助快速开发cesium项目
中文文档:https://gunomniscience.github.io/jesium/
Vue3中使用jesium
- 安装cesium
npm i cesium
- 拷贝node_modules/cesium/Build/Cesium/Assets、node_modules/cesium/Build/Cesium/ThirdParty、node_modules/cesium/Build/Cesium/Widgets、node_modules/cesium/Build/Cesium/Workers目录到项目的public目录下
在main.ts中添加如下代码
import { Ion } from "cesium" import "cesium/Build/Cesium/Widgets/widgets.css"; // 配置cesium初始化 window.CESIUM_BASE_URL = '/'; // / = public目录,如果是放在public/libs/cesium下面那么应该写:/libs/cesium/ Ion.defaultAccessToken = '你的Cesium Ion的token';
安装jesium
npm i jesium
配置已经完成接下来可以使用jesium来快速开发cesium了
<template> <div class="cesium-container" ref="cesiumContainer"></div> </template> <script lang="ts" setup> import {reactive,toRefs,defineComponent, ref, onMounted} from "vue" import { Jesium } from "jesium" const cesiumContainer = ref(); onMounted(() => { const jesium = new Jesium(cesiumContainer.value); }) </script> <style lang="scss" scoped> .cesium-container { width: 100%; height: 100%; } </style>
1.0.60
1 year ago
1.0.36
1 year ago
1.0.35
1 year ago
1.0.34
1 year ago
1.0.39
1 year ago
1.0.38
1 year ago
1.0.40
1 year ago
1.0.44
1 year ago
1.0.43
1 year ago
1.0.42
1 year ago
1.0.41
1 year ago
1.0.48
1 year ago
1.0.47
1 year ago
1.0.46
1 year ago
1.0.45
1 year ago
1.0.49
1 year ago
1.0.51
1 year ago
1.0.50
1 year ago
1.0.55
1 year ago
1.0.54
1 year ago
1.0.53
1 year ago
1.0.52
1 year ago
1.0.59
1 year ago
1.0.58
1 year ago
1.0.57
1 year ago
1.0.56
1 year ago
1.0.33
1 year ago
1.0.32
1 year ago
1.0.19
1 year ago
1.0.18
1 year ago
1.0.16
1 year ago
1.0.9
1 year ago
1.0.8
1 year ago
1.0.22
1 year ago
1.0.21
1 year ago
1.0.20
1 year ago
1.0.26
1 year ago
1.0.24
1 year ago
1.0.23
1 year ago
1.0.29
1 year ago
1.0.28
1 year ago
1.0.10
1 year ago
1.0.31
1 year ago
1.0.30
1 year ago
1.0.15
1 year ago
1.0.14
1 year ago
1.0.13
1 year ago
1.0.12
1 year ago
1.0.7
1 year ago
1.0.6
1 year ago
1.0.5
1 year ago
1.0.4
1 year ago
1.0.3
1 year ago