ViewControllerState interface

Namespace @runic-artifex/views · @runic-artifex/views 0.7.0-preview.5

interface ViewControllerState<TClient extends ViewClient>

One consistent reading of a ViewController. A new object is published for every change.

Properties

source

readonly source: ViewSource<TClient>;

The source this state belongs to.

client

readonly client: TClient | undefined;

The connected or observed client, or undefined until it connects.

state

readonly state: TClient["snapshot"] | undefined;

The latest state, or undefined until the client connects.

error

readonly error: unknown;

The connection failure, if any.

pending

readonly pending: boolean;

True while a connector is connecting.