cesiumjs-core-utilities
Installation
SKILL.md
CesiumJS Core Utilities & Networking
Version baseline: CesiumJS v1.142+ (ES module imports, defaultValue removed in v1.134)
Breaking Change: defaultValue Removed (v1.134)
// WRONG (removed in v1.134)
const name = defaultValue(options.name, "default");
const opts = defaultValue(options, defaultValue.EMPTY_OBJECT);
// CORRECT (v1.134+)
import { Frozen } from "cesium";
const name = options.name ?? "default";
const opts = options ?? Frozen.EMPTY_OBJECT;
Frozen.EMPTY_OBJECT is Object.freeze({}) and Frozen.EMPTY_ARRAY is Object.freeze([]). Use them as safe defaults for options objects and array parameters.