tuil
ReferencePackages@mwillbanks/tuil-workflowAPI

WorkflowTransition

interface exported by @mwillbanks/tuil-workflow.

View rawEdit

interface

Public interface exported by @mwillbanks/tuil-workflow.

export interface WorkflowTransition<TState> {
  readonly from: string;
  readonly to: string;
  readonly when?: (
    context: WorkflowContext<TState>,
  ) => boolean | Promise<boolean>;
}

Members

MemberTypeRequiredDescriptionRelated types
fromstringYesThe from member uses the string contract.
tostringYesThe to member uses the string contract.
when((context: WorkflowContext<TState>) => boolean | Promise<boolean>) | undefinedNoThe when member uses the ((context: WorkflowContext<TState>) => boolean | Promise<boolean>) | undefined contract.WorkflowContext

Parameters

This declaration has no public members.

Returns

This declaration does not return a value.

Throws

No thrown errors are documented for this declaration.

Source

View the secondary source reference

Package

@mwillbanks/tuil-workflow

On this page