Skip to content

Function: getEntityData()

ts
function getEntityData(): Promise<MapEntity[]>;

Returns the currently cached entity-level overrides, in insertion order.

Reflects the most recent setEntityData(entities[]) replacement plus any subsequent setEntityDataById(id, entity) upserts. Also includes entities supplied via init({ entityData: [...] }) until they are superseded by a later setEntityData call.

Returns an empty array before any entity data is set. This is purely an API-side cache — it does NOT query the iframe for its effective entity state; property-wide defaults from setEntityDefaults are NOT included (those are separate from per-entity overrides).

Throws MAPSTED-1090 if called before the API is READY.

Returns

Promise<MapEntity[]>

snapshot of currently set entity overrides