Skip to content
Discussion options

You must be logged in to vote

Thanks for the benchmark. There is a plan for improvement: since transitions are deterministic, we can "cache" transitions so that instead of looking through the state node tree to determine what the enabled transitions are, we'd already know them. That way, the only cost is what happens in assign(...).

So the comparison that needs to be made is arr.concat(...) vs. the other techniques, in this case.

Also, you can use immer with XState instead of arr.concat(...); not sure how much that would make a difference though.

Performance is something that we'll tackle when we've finalized the API changes for v5 👍

Replies: 2 comments 4 replies

Comment options

You must be logged in to vote
1 reply
@ysitbon
Comment options

Answer selected by ysitbon
Comment options

You must be logged in to vote
3 replies
@ChrisShank
Comment options

@ChrisShank
Comment options

@ysitbon
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants