Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

export to scxml file #413

Open
edbek opened this issue Dec 11, 2023 · 4 comments
Open

export to scxml file #413

edbek opened this issue Dec 11, 2023 · 4 comments

Comments

@edbek
Copy link

edbek commented Dec 11, 2023

Is there in xstate-tools an export to scxml file?

@davidkpiano
Copy link
Member

We will eventually have this as a feature in the Stately editor.

There is some tooling in the XState repository itself for converting to SCXML; maybe that can fit your needs? https://github.com/statelyai/xstate/blob/main/packages/core/src/scxml.ts

@edbek
Copy link
Author

edbek commented Dec 12, 2023

Thank you, David!

But, unfortunately, the link you offer does not contain tools for converting js to scxml.
We look forward to seeing you export to a scxml file!

@EduardShaid
Copy link

David,
do you have any plans to export the resulting state machines to files like JSON Scheme, so that you can obtain meta information and, based on it, start working with these machines in different languages, using, for example, a tool such as https://quicktype.io ?
That is, having created my project in the Stately editor, I would like to get a JSON Scheme meta-file from it.
Then, throwing this file into the quicktype converter, I get files for any language I need (for example, C or Go). By embedding these resulting files into the project, I get code that works quickly with the state machine. The speed of working with the state machine is increased due to the fact that the code generated by quicktype.io pre-creates links to all objects of the machine. Thus the interpreter XState works very quickly.

@edbek
Copy link
Author

edbek commented Feb 27, 2024

Apart from mermaid, can we expect to see the state-machine-cat file format appear in tools for exporting to a file?
https://github.com/sverweij/state-machine-cat

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants