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
{{ message }}
This repository has been archived by the owner on Jan 10, 2023. It is now read-only.
I've been spiking out flutter flux and could use some guidance. I have a repo here. Note that my dependency on flutter_flux is a source dependency, due to the binaries on pub being old.
My use case is a login dialog. I already have it working in plain old flutter, but I want to separate the logic out, hence my spiking with flutter_flux. I've left a few TODO comments in the code, but in short I'm a bit stuck on how to do things The Right Way™.
And there's one debilitating bug in my code that I've not found a workaround for yet. I need to pop the modal when authentication succeeds, but I'm doing so from my build method, which of course triggers a setState() or markNeedsBuild() called during build assertion violation. I'm just not sure where else I could do this.
Can someone please offer some guidance?
Thanks
The text was updated successfully, but these errors were encountered:
Sorry if this is a little late. This doesn't really look like a flux question - the Navigator.of.pop() call isn't related to flux. Your solution works because it moves the call outside of the build method, but it seems like a better solution would be to listen for changes to isAuthenticated in the store (outside of your build method) and then make the call to Navigator when you are notified of that change.
Hi,
I've been spiking out flutter flux and could use some guidance. I have a repo here. Note that my dependency on flutter_flux is a source dependency, due to the binaries on pub being old.
My use case is a login dialog. I already have it working in plain old flutter, but I want to separate the logic out, hence my spiking with flutter_flux. I've left a few TODO comments in the code, but in short I'm a bit stuck on how to do things The Right Way™.
And there's one debilitating bug in my code that I've not found a workaround for yet. I need to pop the modal when authentication succeeds, but I'm doing so from my
build
method, which of course triggers asetState() or markNeedsBuild() called during build
assertion violation. I'm just not sure where else I could do this.Can someone please offer some guidance?
Thanks
The text was updated successfully, but these errors were encountered: