AdapterState interface

Functionality for interfacing with Composite adapter state.

Methods

getState()

Get the current State

offStateChange((state: TState) => void)

Unsubscribes the handler to stateChanged events.

onStateChange((state: TState) => void)

Subscribes the handler to stateChanged events.

Method Details

getState()

Get the current State

function getState(): TState

Returns

TState

offStateChange((state: TState) => void)

Unsubscribes the handler to stateChanged events.

function offStateChange(handler: (state: TState) => void)

Parameters

handler

(state: TState) => void

onStateChange((state: TState) => void)

Subscribes the handler to stateChanged events.

function onStateChange(handler: (state: TState) => void)

Parameters

handler

(state: TState) => void