Skip to content

Instantly share code, notes, and snippets.

@christianhg
Last active May 27, 2020 12:24
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save christianhg/04b76b4eb5b1a8cee1b7a19789332751 to your computer and use it in GitHub Desktop.
Save christianhg/04b76b4eb5b1a8cee1b7a19789332751 to your computer and use it in GitHub Desktop.
Generated by XState Viz: https://xstate.js.org/viz
// Available variables:
// - Machine
// - interpret
// - assign
// - send
// - sendParent
// - spawn
// - raise
// - actions
// - XState (all XState exports)
const fetchMachine = Machine({
id: 'selection',
initial: 'idle',
states: {
idle: {
on: {
FOCUS: 'focused'
}
},
focused: {
on: {
SHIFT_DOWN: 'selecting'
}
},
selecting: {
on: {
SHIFT_UP: 'focused'
}
}
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment