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
You're creating a new service every time the component rerenders. You need to memoize the service. This is what useMachine in react-robot does for you.
https://codesandbox.io/s/material-demo-forked-bstq3?file=/demo.js
What I want: idle -> submit -> success (final state)
What I get: idle -> submit -> idle (when press success)
What I'm doing wrong?
P.S. When I use same machine with
react-robot
or other hook library it works as it supposed.The text was updated successfully, but these errors were encountered: