affaan-m avatar

Dart Flutter Patterns

Production Dart and Flutter patterns that cover the stuff you actually need: null safety without bang operators, sealed classes for state hierarchies, async composition with Future.wait, and the widget architecture rules that prevent rebuilds. It walks through BLoC, Riverpod, and Provider with real examples, plus GoRouter setup with reactive auth guards and Dio interceptors with token refresh. The testing section shows you how to wire up BLoC tests and ProviderScope overrides. Honestly, this is the reference you keep open when setting up a new feature or reviewing code that feels off. It's opinionated where it needs to be, like preferring widget classes over methods and being strict about mounted checks after await.

skills.sh installs
5.7K
GitHub stars
300.3K
last updated
Aug 21, 2026

Install

$ npx -y skills add affaan-m/ecc --skill dart-flutter-patterns --agent claude-code

Installs into .claude/skills of the current project.

Files

Dart/Flutter Patterns

When to Use

Use this skill when:

  • Starting a new Flutter feature and need idiomatic patterns for state management, navigation, or data access
  • Reviewing or writing Dart code and need guidance on null safety, sealed types, or async composition
  • Setting up a new Flutter project and choosing between BLoC, Riverpod, or Provider
  • Implementing secure HTTP clients, WebView integration, or local storage
  • Writing tests for Flutter widgets, Cubits, or Riverpod providers
  • Wiring up GoRouter with authentication guards

How It Works

Sponsors

Details

Repository
github.com/affaan-m/ecc
Categories
Frontend Development, Code Review & Quality, Mobile Development
First seen
Jul 14, 2026

More from affaan-m/ecc

All 263
1vinvcn avatarsetup-pre-commitvinvcn/mattpocock-skills-zh-cn在当前仓库设置 Husky pre-commit hooks,集成 lint-staged (Prettier)、类型检查和测试。适用于用户想添加 pre-commit hooks、设置 Husky、配置 lint-staged,或在提交时运行格式化、类型检查和测试时。5.7Kskills.sh installs
2affaan-m avatarecc-guideaffaan-m/eccGuide users through ECC's current agents, skills, commands, hooks, rules, install profiles, and project onboarding by reading the live repository surface before5.5Kskills.sh installs
3web-infra-dev avatarandroid-device-automationweb-infra-dev/midscene-skillsVision-driven Android device automation using Midscene. Operates entirely from screenshots — no DOM or accessibility labels required. Can interact with all visi5.5Kskills.sh installs
4max-sixty avatarworktrunkmax-sixty/worktrunkGuidance for Worktrunk (the `wt` CLI) — git worktree management, hooks, and config. Load when editing .config/wt.toml or ~/.config/worktrunk/config.toml; adding5.5Kskills.sh installs
5ghostsecurity avatarghost-scan-codeghostsecurity/skillsGhost Security - SAST code scanner. Finds security vulnerabilities in source code by planning and executing targeted scans for issues like SQL injection, XSS, B5.5Kskills.sh installs
6wondelai avatarscorecard-marketingwondelai/skillsBuild quiz and assessment funnels that generate qualified leads at 30-50% conversion. Use when the user mentions "quiz funnel", "scorecard", "lead magnet", "sco5.5Kskills.sh installs