A Typescript codegen CLI for XState.
Birthed from a twitter rant. Read this to get an idea of what you're getting yourself in for.
This repository is EXPERIMENTAL. I'm yet even to do readme-driven development. Changes are subject to break things.
yarn global add xstate-codegen
xstate-codegen "src/**/**.machine.ts"
Watches any file with a machine.ts
extension and adds typings for it.
Currently only works with React, but we plan to support other frameworks soon.
Enjoy!