Skip to content
Version: xstate@5.0.0

StateMachine.(constructor)​

Constructs a new instance of the StateMachine class

Signature:

constructor(
config: MachineConfig<TContext, TEvent, any, any, any, any, any, any, TOutput, any>, implementations?: MachineImplementationsSimplified<TContext, TEvent>);

Parameters​

ParameterTypeDescription
configMachineConfig<TContext, TEvent, any, any, any, any, any, any, TOutput, any>
implementationsMachineImplementationsSimplified<TContext, TEvent>(Optional)