brainstorming
brainstorming
You MUST use this before any creative work - creating features, building components, adding functionality, modifying behavior, or planning anything new, in software or out of it (a talk, a business, a renovation).
flutter-riverpod-state-managementImplement reactive state management using Riverpod 3.x with code generation in Flutter. Use when defining providers, building AsyncNotifiers, or overriding providers in tests.
Independent GitHub snapshot · Automated classification · Original documentation governs
Targets Riverpod 3.x. Notifier/AsyncNotifier codegen surface is unchanged from 2.x; Riverpod 3 adds automatic retry with backoff and pause/resume for offline — do not hand-roll retry logic that the framework already provides.
lib/
├── providers/ # Global providers and services
└── features/user/
├── providers/ # Feature-specific providers
└── models/ # @freezed domain models
Use @riverpod annotations for all provider definitions. See implementation examples for full provider and consumer patterns.
Use ConsumerWidget with ref.watch() and AsyncValue.when() for reactive UI. See implementation examples.
@riverpod annotations. Avoid manual Provider definitions.Freezed for all state models.build() to rebuild on changes.build() for side-effects (navigation, dialogs). Never in provider init.onPressed).ProviderScope(overrides: [provider.overrideWithValue(Mock())]).riverpod_lint and custom_lint for cycle detection.ref.listen() in widgets instead.BuildContext into Notifier/Provider.