Skip to content

Instantly share code, notes, and snippets.

@sea-witch
Created November 16, 2020 21:37
Show Gist options
  • Save sea-witch/a3d7b3d7969daf146b02b61c6fc46de1 to your computer and use it in GitHub Desktop.
Save sea-witch/a3d7b3d7969daf146b02b61c6fc46de1 to your computer and use it in GitHub Desktop.
Generated by XState Viz: https://xstate.js.org/viz
const current = Machine({
id: 'video-player',
initial: 'playing_controlsHidden',
context: {
retries: 0
},
states: {
playing_controlsHidden: {
on: {
PRESS_STOP: 'playing_controlsVisible'
}
},
playing_controlsVisible: {
on: {
PRESS_STOP: 'paused_controlsVisible',
}
},
paused_controlsVisible: {
on: {
PRESS_STOP: 'playing_controlsHidden',
}
}
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment