Default local storage to Hive with legacy migration

This commit is contained in:
Rijad Zuzo
2026-02-15 19:17:25 +01:00
parent 21c911ad4c
commit 1502360051
8 changed files with 142 additions and 10 deletions
+7 -2
View File
@@ -26,7 +26,8 @@ flutter run --dart-define=USE_FAKE_BACKEND=true
Default local store:
- `shared_preferences` (stable baseline)
- `Hive` (`USE_HIVE_LOCAL_DB=true` by default)
- first-run migration imports legacy `shared_preferences` payload when present
Optional migration path:
@@ -34,7 +35,11 @@ Optional migration path:
flutter run --dart-define=USE_HIVE_LOCAL_DB=true
```
When enabled, local app state is stored in Hive via the `LocalDataStore` adapter layer.
Use legacy mode explicitly if needed:
```bash
flutter run --dart-define=USE_HIVE_LOCAL_DB=false
```
## Run Tests