Skip to content

Instantly share code, notes, and snippets.

@joemclo
Created November 20, 2019 14:49
Show Gist options
  • Select an option

  • Save joemclo/b45d0ca77055b4b1bcadaddd10d1b6a0 to your computer and use it in GitHub Desktop.

Select an option

Save joemclo/b45d0ca77055b4b1bcadaddd10d1b6a0 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({
key: 'replication',
initial: 'setup',
states: {
setup: {
on: {
ENABLEREPLICATION: 'details',
},
onEntry: [
{ type: 'routeTransition', params: ['vault.cluster.replication'] },
{ type: 'render', level: 'feature', component: 'wizard/replication-setup' },
],
},
details: {
on: {
CONTINUE: 'complete',
},
onEntry: [{ type: 'render', level: 'feature', component: 'wizard/replication-details' }],
},
complete: {
onEntry: ['completeFeature'],
},
},
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment