A comprehensive Flutter project demonstrating a scalable micro frontend architecture using the Flutter Modular framework. This architecture promotes separation of concerns, independent deployment, and team autonomy in large-scale Flutter applications.
- Modular Architecture: Clean separation of features into independent modules
- Micro Frontend Support: Each feature can be developed and deployed independently
- Scalable Structure: Organized codebase that grows with your application
- Dependency Injection: Built-in dependency management with Flutter Modular
- Feature Isolation: Independent feature development and testing
lib/
├── app_module.dart # Root module that bootstraps the application
├── main.dart # Application entry point
packages/
├── features/ # Feature modules (microfrontends)
│ ├── feed/ # Example: Feed feature module
│ ├── login/ # Example: Authentication module
│ └── profile/ # Example: User profile module
│
└── libraries/ # Shared libraries and utilities
├── core/ # Core functionality and shared models
└── ui_components/ # Reusable UI components
This project follows a microfrontend architecture using Flutter Modular, which provides:
- Feature Modules: Self-contained units of functionality
- Lazy Loading: Modules are loaded on-demand
- Dependency Injection: Clean dependency management
- Navigation: Type-safe routing between modules
- Modules: Independent units of functionality
- Routes: Navigation between different modules
- Binds: Dependency injection system
- Child Modules: Nested module structure for complex features
-
Create a new directory under
packages/features/ -
Set up the module structure:
your_feature/ ├── lib/ │ ├── your_feature_module.dart │ ├── pages/ │ └── widgets/ ├── test/ └── pubspec.yaml -
Register the module in
app_module.dart
This project is licensed under the MIT License - see the LICENSE file for details.