— while we are still on the subject of state machines, you can use this tool designed as an abstraction for React

[code][example]