Kaplay.State
Modules
Comp
Values
addStateComponent
addState(context, initialState, stateList)
returns Types.comp
Finite state machine.
let addState: (Kaplay.Context.t, T.t, 't, array<'t>) => Kaplay.Types.comp
Return type
addStateWithTransitionsComponent
addStateWithTransitions(context, initialState, stateList, transitions)
returns Types.comp
Transitions should be an object with keys and values of 't.
let addStateWithTransitions: ( Kaplay.Context.t, T.t, 't, array<'t>, {..},) => Kaplay.Types.comp