riverpod-patterns
Installation
SKILL.md
Iron Law: Always use the correct Riverpod provider type for the use case; never use StateProvider for async data or FutureProvider for mutable state.
Riverpod Patterns
Correct Riverpod patterns for Flutter state management with code_generation style.
When to use: Writing or reviewing Riverpod providers, AsyncNotifier, AsyncValue.when, ref.watch vs ref.read, family providers, or provider lifecycle.
Process:
- Identify pattern needed from user request
- Load reference: Read
reference/riverpod-core-patterns.mdfor code examples and rules - Apply patterns using loaded reference
- Verify: Confirm ref.watch is only in build(), ref.read only in callbacks, all AsyncValue states handled visibly