android-persistence
Installation
SKILL.md
Android Persistence Standards
Priority: P0 (CRITICAL)
1. Configure Room Database
- Return
Flow<List<T>>for queries, usesuspendfor Write/Insert. - Keep
@Entitydata classes simple. Map to Domain models in Repository. - Use
@Transactionfor multi-table queries (Relations).
See DAO templates for Room DAO patterns.
2. Migrate to DataStore
- Replace
SharedPreferenceswithProtoDataStore(type-safe) orPreferencesDataStore. - Inject singleton DataStore instance via Hilt.
See DAO templates for DataStore migration patterns.