-
Notifications
You must be signed in to change notification settings - Fork 42
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
The step handler is not cleared on a transition to the previous step #94
Comments
Hi thanks for creating this issue. This is indeed not expected, I guess you're using the Anyway, at first sight clearing the "nextStepHandler" in the |
Hi, thanks for your quick response @devrnt. Check out this: https://codesandbox.io/s/trusting-mahavira-hkrk7. As you can see both previousStep and goToStep methods are failing. |
Fixed in https://codesandbox.io/s/confident-sun-3pe1i?file=/src/App.js (atm still a pre-release) |
If a step runs handleStep to set a callback to be called when calling nextStep, this callback also executes in a previous step if the user goes backward n steps and then goes forward at some point. For example:
step 1 -> step 2 (prints "going to step 3") -> step 3 (OK)
step 1 -> step 2 -> step 1 (prints "going to step 3") -> step 2 -> step 3 (KO)
The reason is the callback is only cleared during a next step transition:
The text was updated successfully, but these errors were encountered: