Optionaloptions: MachineOptionsOptionallistener: (payload: any) => voidListen for state transitions.
Optionaloptions: ListenerOptionsReturns a promise that resolves when the machine is hydrated from persistence. If no persistence is configured, resolves immediately.
Remove a listener for a state or pattern.