I am working on flutter app and I want you to create a basic Flutter app with multi-screen navigation using go_router. Implement a feature using Riverpod for state management, get_it for dependency injection, and Freezed for data modeling.
make will orignnized structure and seprate file for each help me here
I'll help you create a basic Flutter app with the requested architecture and features. Let's organize it with a clean structure that separates concerns.
This Flutter app implements all the requested features:
Multi-screen navigation with go_router:
State management with Riverpod:
Dependency injection with get_it:
Data modeling with Freezed:
The project follows a clean architecture approach with:
To complete the setup, you'll need to add these dependencies to your pubspec.yaml:
dependencies:
flutter:
sdk: flutter
flutter_riverpod: ^2.3.6
go_router: ^10.0.0
get_it: ^7.6.0
freezed_annotation: ^2.2.0
json_annotation: ^4.8.1
dev_dependencies:
flutter_test:
sdk: flutter
build_runner: ^2.4.6
freezed: ^2.3.5
json_serializable: ^6.7.1After adding these dependencies, run:
flutter pub get
flutter pub run build_runner build --delete-conflicting-outputsThis will generate the necessary Freezed files for your data models.