smart_local_cache 2.0.1
smart_local_cache: ^2.0.1 copied to clipboard
Pure Dart/Flutter local storage — no third-party packages. Save lists of records (with auto or custom ids) to disk as plain Maps, no model classes or code generation needed.
2.0.1 #
Fixed #
- Fixed edge cases where reading a missing key could return an unexpected value instead of
null. - Fixed data type mismatch issues when reading values saved as a different type.
- Improved error handling so storage failures no longer crash the app.
Improved #
- Better performance when reading and writing large data.
- Cleaner internal code and reduced package size.
Docs #
- Updated README with clearer setup and usage steps.
- Added more usage examples in the example app.
2.0.0 #
Breaking Changes #
- Updated the public API for a simpler and more consistent usage.
- Minimum Dart/Flutter SDK constraints were raised. Check
pubspec.yamlbefore upgrading. - Some method names and parameters were changed. See the migration guide below.
Added #
- Support for storing more data types (String, int, double, bool, List, Map).
- Method to check if a key exists.
- Method to clear all stored data.
- Null safety improvements across the package.
Changed #
- Updated all dependencies to their latest versions.
- Rewrote the example app to show the new API.
Migration Guide #
- Update the package version to
^2.0.0inpubspec.yaml. - Run
flutter pub get. - Replace old method calls with the new API names.