- Notifications
You must be signed in to change notification settings - Fork92
🤖 A functional, immutable Finite State Machine library
License
matthewp/robot
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
A small functional and immutable Finite State Machine library. Using state machines for your components brings the declarative programming approach to application state.
Seethisrobot.life for the main documentation.
import{createMachine,interpret,state,transition}from'robot3';letmachine=createMachine({off:state(transition('toggle','on')),on:state(transition('toggle','off'))});constservice=interpret(machine,()=>{render();});
- Please starthe repository on GitHub.
- File an issue if you find a bug. Or better yet...
- Submit a pull request to contribute.
Tests are located in thetest/
folder. Loadtest/test.html
in your browser of choice with any HTTP server you like (I usehttp-server). Tests are written inQUnit and are simple to understand.
Robot works with a variety of UI libraries, and includes integrations for React, Preact, Haunted, and more. See theintegrations page to learn more.
- Visualization of robot state machines:robot3-viz
BSD-2-Clause
About
🤖 A functional, immutable Finite State Machine library
Resources
License
Code of conduct
Contributing
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Packages0
Uh oh!
There was an error while loading.Please reload this page.