dart-flutter-patterns

Provides standardized Flutter implementation patterns for state management, navigation, and async handling.

Updated Mar 26, 2026
One-click install
npx skills add https://github.com/luongldptit/move-ticket --skill dart-flutter-patterns-luongldptit
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: dart-flutter-patterns
Source: https://github.com/luongldptit/move-ticket/tree/main/.agent/skills/dart-flutter-patterns
Command: npx skills add https://github.com/luongldptit/move-ticket --skill dart-flutter-patterns-luongldptit

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill eliminates the hassle of writing inconsistent, error-prone Dart and Flutter code by providing vetted, production-ready patterns for common development tasks like state management, navigation, and async handling.

Core Features & Use Cases

  • Idiomatic Language Patterns: Covers null safety, immutable state, async composition, and widget architecture best practices aligned with Dart and Flutter standards.
  • Ecosystem Integration: Includes ready-to-use patterns for popular packages including BLoC, Riverpod, GoRouter, Dio, and Freezed.
  • Use Case: Use this when building new Flutter features, reviewing existing code, or setting up a new project to avoid common pitfalls and ensure code consistency.

Quick Start

Use the dart-flutter-patterns skill to implement a reactive authentication guard for your Flutter app's GoRouter navigation.

Frequently Asked Questions about dart-flutter-patterns

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
What are the best Flutter state management patterns for production apps?

Standardized Flutter state management patterns for production apps utilize BLoC or Riverpod to enforce immutable state and ensure testable code structures. These vetted patterns eliminate inconsistent, error-prone code by providing reliable architecture for feature development and code reviews.

How do I implement a reactive authentication guard with GoRouter in Flutter?

Implementing a reactive authentication guard with GoRouter in Flutter involves applying standardized navigation patterns that securely redirect users based on authentication state. This approach uses idiomatic Dart async composition to handle routing logic without introducing error-prone code.

Does this Skill provide patterns for both Riverpod and BLoC in Flutter?

Yes, this Skill provides ready-to-use patterns for both Riverpod and BLoC in Flutter. It delivers ecosystem integration patterns for popular packages, ensuring consistent state management, secure HTTP networking with Dio, and widget architecture aligned with Dart standards.

How do I ensure null safety compliance and immutable state in Dart?

Ensuring null safety compliance and immutable state in Dart requires applying idiomatic language patterns during project setup and feature development. Using Freezed for immutable state generation alongside standardized widget architecture patterns prevents common asynchronous composition pitfalls.

What is the best way to structure a new Flutter project for testable code?

The best way to structure a new Flutter project for testable code is applying production-ready clean architecture patterns. This involves standardized state management, secure HTTP networking, and widget architecture patterns that satisfy testing workflows and eliminate inconsistent code.

Can I use these Dart and Flutter patterns for reviewing existing code?

Yes, you can use these Dart and Flutter patterns for reviewing existing code to avoid common pitfalls and ensure consistency. The standardized patterns cover state management, navigation, and async handling, satisfying requirements for null safety and secure HTTP networking.