flutter-core:flutter-persistence

Installation
SKILL.md

Flutter Persistence

Master local data persistence in Flutter applications with comprehensive coverage of key-value storage, relational databases, NoSQL solutions, and file management. This skill provides practical guidance for implementing robust offline-first functionality and efficient data caching strategies.

Core Concepts

Flutter applications require persistent storage to maintain state across app sessions, enable offline functionality, and improve performance through intelligent caching. The Flutter ecosystem provides multiple persistence solutions, each optimized for different use cases and data structures.

Storage Solution Overview

SharedPreferences provides simple key-value storage ideal for user preferences, settings, and small configuration data. It wraps platform-specific storage mechanisms (NSUserDefaults on iOS, SharedPreferences on Android) with an async Dart API supporting primitives and string lists.

SQLite (via sqflite) offers full relational database capabilities with SQL query support, transactions, and ACID compliance. It excels at structured data with complex relationships, supporting joins, indexes, and migrations for evolving schemas.

Hive delivers high-performance NoSQL storage with a pure Dart implementation requiring no native dependencies. It provides type-safe box-based storage with built-in encryption, making it ideal for fast key-value access and offline-first apps across all platforms including web.

Drift builds on SQLite with compile-time type safety, generating Dart classes from database schemas. It provides reactive streams, DAO patterns, and fluent query builders while maintaining full SQL power for complex queries.

File Storage enables direct file system access through the path_provider package, supporting custom formats, large binary data, and document management with platform-agnostic directory paths.

Installs
1
GitHub Stars
2
First Seen
Mar 31, 2026
flutter-core:flutter-persistence — aaronbassett/aaronbassett-marketplace