You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I would like to be able to prevent certain transitions by adding logic to check the data attribute in onBeforeTransition. It's not immediately clear how best to update the code to support this. Thanks in advance for any help you can provide.
The text was updated successfully, but these errors were encountered:
Hi there. I was just wandering by, and I saw your comment. Hopefully, you found a solution by now, but someone else might have the same question.
Unless I'm mistaken, that breaks the rules of finite state machines. You might need a more complex model. You could create a class or pure object with all the methods, state, and rules; or you could add more states to your machine to cover all the cases.
Edit:
It looks like you might also be able to accomplish something like this with "conditional transitions." If the data doesn't look good, you can redirect to a different state.
I would like to be able to prevent certain transitions by adding logic to check the data attribute in
onBeforeTransition
. It's not immediately clear how best to update the code to support this. Thanks in advance for any help you can provide.The text was updated successfully, but these errors were encountered: