stacked
3.5.0, released a year ago by filledstacks.com
A complete frontend architecture framework for building Flutter applications.
What it does
Stacked provides a full architectural framework for Flutter applications, handling state management, dependency injection, and navigation. It utilizes ViewModels to separate UI from business logic to keep apps testable and scalable.
AI-written summary of version 3.5.0, based on the package's README and metadata. Report an inaccuracy
Use it when
- You want a complete out-of-the-box architecture for production apps
- You prefer MVVM pattern with ViewModels and services
- You need structured navigation, dependency injection, and state management combined
Skip it when
- You prefer a minimal, unopinionated state management solution
- You use Riverpod or BLoC and want to stick to those paradigms
Strengths
- Provides a complete architectural standard out of the box
- Built-in support for dependency injection and routing
- Makes testing business logic via ViewModels straightforward
Weaknesses
- Opinionated framework that locks you into its specific structure
- Steeper learning curve for developers used to simpler state holders
Setup
- Kind
- Flutter widgets
- Effort
- Medium
- Code generation
- No
- Direct dependencies
- 8
Requires setting up the recommended folder structure and registering services with the built-in dependency injection container.
not documentedAlternatives
Packages that do the same job and could replace stacked.
- flutter_bloc
If you prefer a strict predictable state management pattern based on events and states.
86Compare - flutter_riverpod
If you want a compile-safe, provider-based dependency and state management approach.
93Compare - get
If you want lightweight routing, dependency injection, and state management without a rigid architecture.
81Compare
Works with
Packages commonly used together with stacked: ones it builds on, ones built on it, and its own family.
- webstacked depends on itLightweight bindings for browser APIs via JS interop
- universal_iostacked depends on itCross-platform dart:io implementation with browser support for HttpClient and other APIs
- get_itstacked depends on itA fast, type-safe service locator for Dart and Flutter without BuildContext or code generation.
- providerstacked depends on itA lightweight wrapper around InheritedWidget for state management
- stacked_sharedstacked depends on itShared code between the stacked packages.
- stacked_generatorSame familyGenerates routing and dependency‑injection boilerplate for Stacked apps.
- stacked_hooksSame familyClasses that help use Flutter Hooks with the stacked package architecture.
- stacked_themesSame familyManage multiple themes, dark mode, and theme persistence in Flutter applications.