Replies: 1 comment 1 reply
-
Typed actor systems aren't currently supported. There are generic type parameters for a system in all the right places in the api but they're currently set to I believe this is because there currently isn't a mechanism for defining a system as a whole. Right now actors have an implicit @davidkpiano critique my explanation? |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi there. I am interested in implementing the actor model in the front end of my application. But I am struggling with Systems in Xstate. In particular, how to use Systems with Typescript.
For example, I have a root machine with a setup that declares two actors:
At some of the states of the root machine, I invoke these child machines:
Then, in another actor of the same system, I try to get this actor from the system:
It works in runtime. But how do you get type safety with Systems? Because now it's
const someActor: any
. The documentation does not explain this. Am I missing something?Beta Was this translation helpful? Give feedback.
All reactions