flutter_clean_architecture
6.2.0, released 10 months ago by an unverified publisher
A Flutter package implementing Uncle Bob's Clean Architecture with Views, Controllers, and UseCases.
What it does
Implements Uncle Bob's Clean Architecture by providing structured components such as Views, Controllers, Presenters, Observers, and UseCases. It enforces separation of concerns through distinct Domain, App, Data, and Device layers.
AI-written summary of version 6.2.0, based on the package's README and metadata. Report an inaccuracy
Use it when
- You want to rigidly enforce Clean Architecture principles in a Flutter application.
- You prefer an explicit separation between business logic (Domain layer) and UI presentation (App layer).
Skip it when
- You prefer lightweight, modern state management solutions like Riverpod or Bloc.
- You want to avoid heavy boilerplate and architectural constraints on smaller projects.
Strengths
- Enforces strict architectural boundaries and testable business logic.
- Provides a built-in separation of Views, Controllers, and Presenters.
Weaknesses
- Introduces high architectural overhead and boilerplate for simple apps.
- Steep learning curve for developers unfamiliar with Clean Architecture.
Setup
- Kind
- Flutter widgets
- Effort
- Low
- Code generation
- No
- Direct dependencies
- 6
No native permissions or build_runner required; simply add the dependency to pubspec.yaml and follow the layered folder structure.
import 'package:flutter_clean_architecture/flutter_clean_architecture.dart';Alternatives
Packages that do the same job and could replace flutter_clean_architecture.
- riverpod
Offers a more robust, compile-safe, and modern approach to state management and dependency injection without heavy Clean Architecture boilerplate.
99Compare - bloc
Provides a predictable state management pattern based on streams and events that fits well into layered architectures without dictating a full Uncle Bob structure.
92Compare
Works with
Packages commonly used together with flutter_clean_architecture: ones it builds on, ones built on it, and its own family.
- argsflutter_clean_architecture depends on itLibrary for parsing raw command-line arguments into options and values using GNU and POSIX styles.
- loggingflutter_clean_architecture depends on itProvides configurable logging with levels and stream listeners for Dart apps.
- rxdartflutter_clean_architecture depends on itImplementation of the ReactiveX API for asynchronous programming leveraging native Dart Streams.
- providerflutter_clean_architecture depends on itA lightweight wrapper around InheritedWidget for state management
- responsive_builderflutter_clean_architecture depends on itWidgets for responsive UI across device types and orientations