#Adding conditional operators to inline guards ?
1 messages · Page 1 of 1 (latest)
it looks like you should be able to do that
you just need to pass them as Array
A guard is a condition function that the machine checks when it goes through an event. If the condition is true, the machine follows the transition to the next state. If the condition is false, the machine follows the rest of the conditions to the next state.
guard: or([
stateIn('someStateB'),
stateIn('someStateA'),
]),
and ofcourse you need to import and/or 🙂
Yep, thanks @magic crater - that's correct