Discussion

Flutter – shared preference

This wraps NSUserDefaults (on iOS) and SharedPreferences (on Android), providing a persistent store for simple data. Data is persisted to disk asynchronously. Neither platform can guarantee that writes will be persisted to disk after returning and this plugin must not be used for storing critical data.

Plugin: https://pub.dev/packages/shared_preferences

To use this plugin, add shared_preferences as a dependency in your pubspec.yaml file.

You may also like...

Leave a Reply

Your email address will not be published. Required fields are marked *