Skip to main content

Function: getState()

function getState<T = unknown>(path?: string): AppStateShape | T | undefined;

Defined in: utils/state/core/stateManager.ts:374

Gets state by dot-notation path.

Type Parameters​

T​

T = unknown

Parameters​

path?​

string = ""

Dot-notation path to a state property.

Returns​

| AppStateShape | T | undefined

State value at the path, or the root state for an empty path.