I'm making a simple "dictionary" app to learn Flutter. The basic idea is that the user can add a word to his dictionary.
I have a class named Word (term, definition, examples in a list) but now I need to save the added words so the user can maintain them even when he closes the app.
I've heard about shared preferences and SQLite database but what would be the best approach in this case?
There are many packages for local storage in flutter:
Here is some:
1. Shared_preferences
Flutter plugin for reading and writing simple key-value pairs. Wraps NSUserDefaults on iOS and SharedPreferences on Android.
2. Sqflite
Flutter plugin for SQLite, a self-contained, high-reliability, embedded, SQL database engine.
3. Hive
Lightweight and blazing fast key-value database written in pure Dart. Strongly encrypted using AES-256.
4. Sembast
NoSQL persistent embedded file system document-based database for Dart VM and Flutter with encryption support.
5. Flutter_secure_storage
Flutter Secure Storage provides API to store data in secure storage. Keychain is used in iOS, KeyStore based solution is used in Android.
6. Moor Moor is a safe and reactive persistence library for Dart applications
7. Floor
The typesafe, reactive, and lightweight SQLite abstraction for your Flutter applications. This library is the runtime dependency.
8. Localstorage
Simple json file-based storage fo flutter. Alternative to react-native AsyncStorage
9. Objectbox
ObjectBox is a super-fast NoSQL ACID compliant object database.
10. Json_store
A Flutter storage solution somewhat similar to a browser's localStorage (but super powered)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With