Events Stop Propagating Once Handled
{
initial: "active",
context: { count: 0 },
states: {
active: {
on: {
COUNT: {
actions: "changeCount",
},
},
initial: "increment",
states: {
increment: {
on: {
SWITCH_COUNT_DIRECTION: "decrement",
},
},
decrement: {
on: {
SWITCH_COUNT_DIRECTION: "increment",
COUNT: {
actions: 'logEvent'
},
},
},
},
},
},
};PreviousInline Actions vs Actions In Machine OptionsNextDefine Event That Does Internal Self Transition
Last updated