-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Bug: invoke id callback not typed as a function #4605
Comments
v4 didn't allow dynamic IDs on |
Awesome, thank you. Dynamic id's are just what I needed! |
This turned out to be slightly more complicated than I anticipated since we were relying on those particular IDs to be static. This bit of the implementation is funky - so perhaps this will force us to rethink what we are doing there in terms of how we allow for entry |
XState version
XState version 5
Description
The id can be used as a callback but I am getting typescript errors. Wondering its a bug in the typing or is this a bug in that it shouldnt take a callback?
Expected result
i expect only a string to work because thats what the typing is.
Actual result
A callback is what i need but the ts support isnt correct and shows an error.
Reproduction
https://codesandbox.io/p/devbox/dreamy-hill-ht77kt?file=%2Fsrc%2FfeedbackMachine.ts%3A44%2C9
Additional context
No response
The text was updated successfully, but these errors were encountered: