flutter-auth-ui icon indicating copy to clipboard operation
flutter-auth-ui copied to clipboard

How to implement persistent email / password field between signup/signin/magiclink/resetpassword

Open cgestes opened this issue 3 years ago • 3 comments

Hi,

if the feature make sense for the library, do you have an idea of how we could provide persistence between screens?

Probably we should support two use cases:

  • persistently store the email to reuse at next sign in
  • temporarily store email / password between the relevant screens

Which screen should support that? ie does it make sense for reset password?

Passing a default initialEmail/initialPassword is a bit annoying, cause with go_router when changing screens the supabase components may not change instance and those not use the new initialEmail/initialPassword

cgestes avatar Sep 30 '22 09:09 cgestes

I love the idea of persisting text field values across widgets!

persistently store the email to reuse at next sign in

I don't know if this behavior is common in apps in general, but do you have any example apps that have this behavior?

temporarily store email / password between the relevant screens

I don't think there is a single correct solution for implementing this! Any way to achieve it would be fine, I think!

dshukertjr avatar Sep 30 '22 12:09 dshukertjr

I don't know if this behavior is common in apps in general, but do you have any example apps that have this behavior?

signing in into google? :D

I'am not sure it belongs in this repo, but it would make sense to make it possible.

Ok we will think about a design.

cgestes avatar Sep 30 '22 14:09 cgestes

Just a simple one. Provide additional parameters in order to inject the email and/or the password with your custom ones, so you can setup your prefered persistency mechanism.

henry2man avatar Apr 18 '24 08:04 henry2man