-
Notifications
You must be signed in to change notification settings - Fork 92
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
Keep User Logged in #174
Comments
Hello there!👋 Welcome to the project!🚀⚡ |
I want to add this feature please assign this issue to me. |
@ishandeveloper @smaranjitghose @anushbhatia @Rishabh510 Should we use shred preferences here or StreamBuilder? |
Shared Prefs seems like a better option to me, what do you think? |
Using StreamBuilder we can just check for onAuthStateChanged flag and direct the user accordingly. Its just like if else and much better as we are anyway requiring internet connection for connecting to Firebase. So it makes sense rather using Shared Prefs. |
We have to decide between the two of them. I'll finalise it tomorrow. |
Last time I used Streambuilder with firebase auth, the initial load times for my app to go from splash screen to actual home screen were significantly larger. I believe with the shared prefs approach, that won't be the case. Still, I'm open to the idea of using streambuilder, if that better fits our use case. What do you think? |
We can go with shared_prefs as well. The difference is we connect with Firebase Server when using Streambuilder and with local device storage when using shared_prefs and then later with Firebase Server to initiate login request. Also, we can show the Splash screen only till we get the user authentication status from Firebase and then move over to the Home Page of the application. I recommended Streambuilder since it is easy to work with and doesn't require an extra package. |
@Mus2413 You can go ahead with streambuilder for keeping user logged in: Instead of Indicator you can show the dashboard |
Okay
…On Fri, 2 Apr, 2021, 9:15 pm HIMANSHU SHARMA, ***@***.***> wrote:
@Mus2413 <https://github.com/Mus2413> You can go ahead with streambuilder
for keeping user logged in:
[image: image]
<https://user-images.githubusercontent.com/44980497/113430836-7dff7c00-93f8-11eb-98f2-d64bb7679d40.png>
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#174 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ANSA7LIN6R65NT6VXZ2MCNTTGXRCDANCNFSM4Z6C4SJA>
.
|
Hey @himanshusharma89 we can use FirebaseAuth.Currentuser.uid This way the user will be signed if he/she hasn't loggedout Should i work on this issue under gssoc? |
@anotherwebguy The above stream will do the same and this issue is already assigned to @Mus2413. BTW @Mus2413, any update on this issue? |
I am working on it...
…On Tue, 6 Apr, 2021, 9:00 pm HIMANSHU SHARMA, ***@***.***> wrote:
@anotherwebguy <https://github.com/anotherwebguy> The above stream will
do the same and this issue is already assigned to @Mus2413
<https://github.com/Mus2413>. BTW @Mus2413 <https://github.com/Mus2413>,
any update on this issue?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#174 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ANSA7LJ5JRVDJUARQPUOXFTTHMSJBANCNFSM4Z6C4SJA>
.
|
Feature Request ✨
Use Case
Possible Solution
Context
Detailed Description
After the user quit the app and returns back , then they have to logged in again. I want to add one feature which will keep user signed in .
The text was updated successfully, but these errors were encountered: