Created
December 11, 2019 17:29
-
-
Save Jpadilla1/1c8e6a282a4a260fdf0b5319a3f115b1 to your computer and use it in GitHub Desktop.
Generated by XState Viz: https://xstate.js.org/viz
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const sparkStatus = Machine({ | |
id: 'status-machine', | |
initial: 'setup', | |
context: { | |
sparkActor: null, | |
}, | |
states: { | |
setup: { | |
entry: 'spawnSparkStatusUpdater', | |
on: { | |
'': 'disabled', | |
}, | |
}, | |
disabled: { | |
on: { | |
success: 'enabled', | |
}, | |
}, | |
enabled: { | |
on: { | |
failure: 'disabled', | |
}, | |
}, | |
}, | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment