开发与测试
Building Flutter Apps
A strict Flutter architecture skill for AI agents enforcing Riverpod, Freezed, GoRouter patterns with local enforcement.
sgaabdu4 · 已有 AI 审核记录
安装与使用
运行命令前先阅读来源与依赖说明。复制命令不会自动安装或执行。
npx skills add sgaabdu4/building-flutter-apps技能说明
Building Flutter Apps
A strict Flutter architecture skill and plugin for teams that want Riverpod, Freezed, typed GoRouter, Hive CE, localization, tests, accessibility, and runtime proof enforced the same way every time.
This is not a generic Flutter tips repo. It is an opinionated policy package for building Flutter apps with one clear architecture and enough local enforcement that an agent cannot quietly drift into weaker patterns.
It is unofficial. It is not affiliated with Google, Flutter, Dart, Riverpod, or their maintainers.
What It Enforces
The target app shape is simple:
UI widgets
-> generated Riverpod providers and notifiers
-> repositories
-> local or remote datasources
-> APIs, Hive boxes, platform plugins
Domain entities stay pure Dart.
Navigation goes through typed GoRouter routes.
User-facing copy goes through gen-l10n.
Behavior is proven with tests, lints, hooks, evals, and E2E evidence.
The main rules:
- Providers are generated with
@riverpod/@Riverpod; manual provider constructors are out. - State and domain models use sealed Freezed classes; hand-written immutable patterns are out.
- Widgets render and dispatch only. Business logic, storage, networking, and policy live behind their owning provider, notifier, repository, datasource, or service.
- Async work is guarded with
ref.mountedorcontext.mounted. - Domain primitives with meaning become Value Objects.
- Route strings are owned by typed GoRout