types_cesium

Standalone typescript definition file for Cesium JS

cesium · cesiumjs · gis · typescript
入门
GitHub在线演示
Stars:6
License:Apache License 2.0
更新:2024/12/20

README

npm apache license

@types/cesium

Standalone typescript definition file for Cesium JS.

Why?

Have you seen how large cesium is? I just need the types.

I have a build pipeline with some expensive steps like js minification, and including Cesium makes it really slow (60+ mb). With @platypii/cesium, typescript is happy, and I can just include cesium directly in my webpage without slowing down my build process.

It is also useful to see the diff of the cesium api over time.

How to use

Add to package.json:

{
  "devDependencies": {
    "@platypii/cesium": "^1.103.0",
  }
}

Add to tsconfig.json:

{
  "compilerOptions": {
    "typeRoots": [
      "node_modules/@types",
      "node_modules/@platypii"
    ]
  }
}

Publishing

npm publish