Skip to content

Profectus / game/layers / reloadLayer

Function: reloadLayer() ​

reloadLayer(layer): void

Convenience method for removing and immediately re-adding a layer. This is useful for layers with dynamic content, to ensure persistent refs are correctly configured.

Parameters ​

layer ​

Layer

Layer to remove and then re-add

Returns ​

void

Defined in ​

profectus/src/game/layers.tsx:359