Closed GitHubGreg closed 5 years ago
And even if they enter another scene that also calls the state.status.error conditionally, it will still show the error message even if it is a completely unrelated scene.
I'd suggest maintaining success/error/info/loading statuses on a container-component level, opposed to storing it in Redux. It avoids issues like you've described, and really doesn't need to be in an app-wide store (given they're typically specific to an individual screen/function at a point in time).
It's the pattern I lean toward - and does need to be changed in this repo. Happy to accept a PR if you get a moment?
Makes sense. If I can find the time I will be happy to do it. Thanks for this great repo.
If a user gets an error message on the signup scene (e.g. First name is missing), and then leaves that scene with the back button, then returns to the scene, they still see the error message. Is there a way to reset the scene (or the state.status.error) so that when they return to the scene it is new again? Thanks.