Skip to content

Instantly share code, notes, and snippets.

@vuhrmeister
Last active April 16, 2020 12:47
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 vuhrmeister/42f5ec365f06a8a6ffc246c746ff6489 to your computer and use it in GitHub Desktop.
Save vuhrmeister/42f5ec365f06a8a6ffc246c746ff6489 to your computer and use it in GitHub Desktop.
Generated by XState Viz: https://xstate.js.org/viz
const channelMachine = Machine({
initial: 'joining',
states: {
joining: {
},
joined: {
on: {
// Error thrown: TypeError: Cannot read property 'target' of null
// JOINED: null
JOINED: undefined
}
},
done: {
type: 'final'
}
},
on: {
JOINED: {
target: 'joined',
actions: sendParent('CHANNEL_JOINED')
}
}
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment