This is a NodeJS - react app.
To run this code on your local machine:
- install nodejs
- open the project in vs code or (any other editor would work)
- while your current working directory (cwd) is this project, run the following command
npm install
- when all the packages are installed you can run the application:
node start
to see the state machine visually, follow the steps:
- Install via the Visual Studio Code Marketplace →
- Once installed, you can run XState: Open Visual Editor from the command palette to open any machine at your cursor's location.
- If you have code lens enabled (this can be enabled using editor.codeLens setting), you'll also see 'Open Visual Editor' floating above each createMachine call.
See the state machine on stately.ai