I'm new to flutter and I really want an answer to my question. Thank you in advance. So I have a WebView project in flutter and I want to add my own page of authentication at first when you open the page and I don't know if there is a way the user can authenticate from this page with the cache of my WebView. Sorry if my question is not clear but I really need this in my project. Please if someone has a source code of something like this, Please share it with me.
CodePudding user response:
Your question is not clear that much but I think you want to save the user login details when a user login from a WebView and the user doesn't have to re-login again and again when the user closes the app.
If this is what you want to know then you have to use Shared_preferences
shared_preferences: ^2.0.13
what is shared preferences?
SharedPreferences is used for storing data key-value pairs in Android and iOS. SharedPreferences in flutter uses NSUserDefaultson iOS and SharedPreferences on Android, providing a persistent store for simple data.