Last active
July 27, 2021 10:01
-
-
Save hiroMTB/693c005df5f058ede72f972e8e60ecac 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
// Available variables: | |
// - Machine | |
// - interpret | |
// - assign | |
// - send | |
// - sendParent | |
// - spawn | |
// - raise | |
// - actions | |
// - XState (all XState exports) | |
const fetchMachine = Machine({ | |
id: 'sv_office', | |
initial: 'title', | |
context: { | |
retries: 0 | |
}, | |
states: { | |
title: { | |
on: { | |
OK: 'intro' | |
} | |
}, | |
intro: { | |
on: { | |
OK: 'office_intro', | |
} | |
}, | |
office_intro: { | |
on: { | |
OK: 'sv_office', | |
} | |
}, | |
sv_office: { | |
on: { | |
Desk: "Desk", | |
Walls: "Walls", | |
Vox: "Vox", | |
} | |
}, | |
Desk: { | |
on: { | |
OK: "sv_office" | |
} | |
}, | |
Walls: { | |
on: { | |
OK: "sv_office" | |
} | |
}, | |
Vox: { | |
on: { | |
OK: "puzzle1a" | |
} | |
}, | |
puzzle1a: { | |
on: { | |
OK: "sv_office" | |
} | |
} | |
} | |
}); | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment