
Security News
Axios Maintainer Confirms Social Engineering Attack Behind npm Compromise
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.
create-cesiumjs
Advanced tools
A scaffolding tool to quickly create CesiumJS geospatial visualization projects, supporting HTML, Vue3 + Vite, and React18 + Vite templates
Create a production-ready CesiumJS geospatial visualization project in seconds with npm create cesiumjs (or npm init cesiumjs—both work!). This official-style starter automates project setup, dependency installation, and Cesium asset configuration, supporting HTML (no framework), Vue3 + Vite, and React18 + Vite templates.
Get a CesiumJS project running in 3 steps:
Initialize the project
Run one of the following commands (they’re identical in functionality):
# Using "create" (modern npm convention)
npm create cesiumjs@latest
# Or using "init" (legacy-compatible)
npm init cesiumjs@latest
Answer the prompts
The CLI will guide you through setup with simple questions:
cesiumjs-project (press Enter to use, or type a custom name).HTML (No framework, pure frontend demo)Vue3 + Vite (Component-based development)React18 + Vite (Component-based development)latest (default) or specify a version (e.g., 1.117.0).Yes (default) to auto-install, or No for manual setup.Run the project
Navigate to your project folder and start the development server:
# Enter the project directory
cd your-project-name
# Start the dev server (works for all templates)
npm run dev
Open http://localhost:5173 (Vite’s default port) in your browser—you’ll see a 3D Cesium globe ready to customize!
Every project generated by npm create cesiumjs includes:
public/cesium/.npm run build, npm run preview).The starter generates a clean, maintainable structure based on your template choice. Below are examples for each supported stack:
Best for quick prototypes or vanilla JS projects:
your-project-name/
├── public/
│ └── cesium/ # Cesium core assets (auto-copied)
│ ├── Assets/ # Terrain, imagery, and 3D models
│ ├── ThirdParty/ # Dependencies like require.js
│ ├── Workers/ # Background processing scripts
│ ├── Widgets/ # UI controls (zoom, timeline, etc.)
│ ├── Cesium.js # CesiumJS UMD bundle
│ └── index.js # CesiumJS ES module entry
├── index.html # Main file (Cesium Viewer initialized here)
├── package.json # Dependencies + scripts
└── README.md # Project docs (customized for your template)
For component-based Vue projects (includes vite-plugin-cesium for optimization):
your-project-name/
├── public/
│ └── cesium/ # Cesium assets (auto-configured)
├── src/
│ ├── components/
│ │ └── CesiumMap.vue # Reusable Cesium Viewer component
│ ├── main.js # Vue entry (mounts App)
│ └── App.vue # Root component (uses CesiumMap)
├── index.html
├── package.json
├── vite.config.js # Vite + Cesium plugin config (pre-setup)
└── README.md
For React projects (optimized for React’s component model):
your-project-name/
├── public/
│ └── cesium/ # Cesium assets (auto-configured)
├── src/
│ ├── components/
│ │ └── CesiumMap.jsx # Reusable Cesium Viewer component
│ ├── main.jsx # React entry (renders App)
│ └── App.jsx # Root component (uses CesiumMap)
├── index.html
├── package.json
├── vite.config.js # Vite + Cesium plugin config (pre-setup)
└── README.md
CesiumJS requires an Ion Token to access cloud-based terrain, imagery (e.g., Bing Maps), and 3D models. Here’s how to set it up:
Get a free token
Add the token to your project
The starter includes a YOUR_CESIUM_ION_TOKEN placeholder in your code—replace it with your real token:
| Template | Where to Replace the Token |
|---|---|
| HTML | In index.html (search for Cesium.Ion.defaultAccessToken) |
| Vue3 | In src/components/CesiumMap.vue |
| React18 | In src/components/CesiumMap.jsx |
Example (HTML template):
// Before (placeholder)
Cesium.Ion.defaultAccessToken = "YOUR_CESIUM_ION_TOKEN";
// After (with real token)
Cesium.Ion.defaultAccessToken = "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..."; // Your token here
All generated projects include standardized scripts in package.json—use them for every development workflow:
| Script | Purpose |
|---|---|
npm run dev | Start the development server (auto-reloads on code changes). |
npm run build | Build the project for production (optimized, minified assets). |
npm run preview | Preview the production build locally (before deploying). |
npm run clean | Delete the dist/ folder (production builds) and node_modules/.cache |
npm init or npm 7+ for npm create).npm install -g npm@latest
Then re-run npm create cesiumjs@latest.public/cesium/—if this step was skipped (e.g., manual dependency install), assets will be missing.npm run copy:cesium-assets
vite-plugin-cesium (pre-configured in vite.config.js). Ensure you’re using the generated CesiumMap component— it includes the correct imports:
// Vue example (src/components/CesiumMap.vue)
import { Viewer } from 'cesium';
import 'cesium/Build/Cesium/Widgets/widgets.css';
assetId in your viewer code).Cesium.IonResource.fromAssetId().viewer.entities.add() to draw points/lines, viewer.camera.flyTo() to navigate to locations).The starter automatically installs all required dependencies based on your template:
| Template | Core Dependencies |
|---|---|
| HTML | cesium, serve (for static file serving) |
| Vue3 + Vite | cesium, vue@^3.4.0, vite@^5.0.0, @vitejs/plugin-vue, vite-plugin-cesium |
| React18 + Vite | cesium, react@^18.2.0, react-dom@^18.2.0, vite@^5.0.0, @vitejs/plugin-react, vite-plugin-cesium |
For bug reports or feature requests, visit the CesiumJS Starter Git Repository (fictional link for documentation purposes).
FAQs
A scaffolding tool to quickly create CesiumJS geospatial visualization projects, supporting HTML, Vue3 + Vite, and React18 + Vite templates
The npm package create-cesiumjs receives a total of 20 weekly downloads. As such, create-cesiumjs popularity was classified as not popular.
We found that create-cesiumjs demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.

Security News
The Axios compromise shows how time-dependent dependency resolution makes exposure harder to detect and contain.