-
Notifications
You must be signed in to change notification settings - Fork 49
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
Reset form #66
Comments
To future travelers, I was able to reset the form by changing the |
A working example of this would be really helpful. |
@JayBox325 I no longer have access to that codebase, but literally as simple as the below. :) Not the most elegant thing, but just exploiting the react-ism that changing a key forces a component to re-render (and wipe its state)! <MailchimpSubscribe key={someValueYouChangeWhenYouWantToReset} /> or, on a parent: <MyModalThatContainsMailchimpSubscribe key={someValueYouChangeWhenYouWantToReset} /> |
There is some way to reset the form after return success?
The text was updated successfully, but these errors were encountered: