Rxova
Skip to content

Type Alias: NavigationWork<TContext, TStepId, TSnap, TResult>

@rxova/journey-react


@rxova/journey-react / NavigationWork

type NavigationWork<TContext, TStepId, TSnap, TResult> = object;

Defined in: core/src/core/types.ts:422

Transactional work attached to next/previous navigation.

run is awaited before movement. If it throws, rejects, or times out, the machine stays on the current step. commit runs synchronously after run succeeds; its context updates are staged and published atomically with the position change.

Type ParameterDefault type
TContext-
TStepId extends string-
TSnap-
TResultvoid
readonly optional commit?: (args) => void;

Defined in: core/src/core/types.ts:424

ParameterType
argsNavigationWorkArgs<TStepId, TSnap> & object

void


readonly run: (args) => TResult | Promise<TResult>;

Defined in: core/src/core/types.ts:423

ParameterType
argsNavigationWorkArgs<TStepId, TSnap>

TResult | Promise<TResult>


readonly optional timeoutMs?: number;

Defined in: core/src/core/types.ts:434

Budget for this run, overriding defaultTimeoutMs. Left unset, the global default applies; set it when this one call is slower than the rest.