Cesium components for Vue 2.x that can help you load Cesium built package or other third-party packages which are built on Cesium.
Branch: master
Clone or download
Latest commit 4034892 Jan 22, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
build update Dec 3, 2018
docs upadate Jan 22, 2019
src upadate Jan 22, 2019
.babelrc update Dec 3, 2018
.eslintrc.js first commit Apr 13, 2018
.gitignore update settings Oct 25, 2018
.npmignore 更新npmignore Nov 20, 2018
.travis.yml 更新Travis配置 Nov 19, 2018
CONTRIBUTING.md update Nov 21, 2018
LICENSE update Nov 7, 2018
README.md update Dec 27, 2018
README.zh.md update Dec 27, 2018
index.d.ts update Oct 25, 2018
package-lock.json update Dec 3, 2018
package.json update Dec 13, 2018
server.js add server Nov 21, 2018

README.md

VUE CESIUM

Cesium components for Vue 2.x that can help you load Cesium built package or other third-party packages which are built on Cesium.

npm Travis Package Quality npm license

Languages

Documentation

Get Start

Amateur learning Vue component development, continuous development.

Installation

npm i --save vue-cesium

Initialization

import Vue from 'vue'
import VueCesium from 'vue-cesium'
// Vue-Cesium will load Cesium.js from `https://unpkg.com/cesium/Build/Cesium/Cesium.js`
Vue.use(VueCesium)
import Vue from 'vue'
import VueCesium from 'vue-cesium'

Vue.use(VueCesium, {
  // cesiumPath is path of Cesium.js', for example:
  // local Cesium Build package:
  // cesiumPath: /static/Cesium/Cesium.js
  // Personal online Cesium Build package:
  // cesiumPath: 'https://zouyaoji.top/vue-cesium/statics/Cesium/Cesium.js'
  // Personal online SuperMap Cesium Build package:
  // cesiumPath: 'https://zouyaoji.top/vue-cesium/statics/SuperMapCesium/Cesium.js'
  // Official Online Cesium Build package:
  cesiumPath: 'https://unpkg.com/cesium/Build/Cesium/Cesium.js'
})

Usage

<template>
  <div class="viewer">
    <cesium-viewer>
    </cesium-viewer>
  </div>
</template>

<style>
.viewer {
  width: 100%;
  height: 400px;
}
</style>

Contributing

Contributing Guide

License

MIT License

Copyright (c) 2018-present, zouyaoji 370681295@qq.com

Thanks

I referenced a lot from the vue-baidu-map project. Thanks very much!