This is a Flutter application for submitting volunteer talent information through a multi-step form. The project is built with a focus on clean architecture, scalability, and maintainability.
The project follows the principles of Clean Architecture, separating concerns into three main layers:
-
Presentation Layer: Contains the UI (Widgets) and state management (BLoC). It is responsible for displaying data and capturing user input.
- Location:
lib/features/talent_submission/presentation - State Management: Uses
flutter_blocto manage the form's state and events.
- Location:
-
Domain Layer: Contains the core business logic and rules of the application. This layer is independent of any framework.
- Location:
lib/features/talent_submission/domain - Key Components:
Entities: Plain Dart objects representing the core data models (e.g.,VolunteerEntity).Repositories: Abstract contracts for data operations.Use Cases: Encapsulate specific business logic for a single task (e.g.,SubmitVolunteer).
- Location:
-
Data Layer: Responsible for data retrieval and storage. It implements the repository contracts defined in the domain layer.
- Location:
lib/features/talent_submission/data - Key Components:
Data Sources: Communicate with external sources like a REST API (TalentSubmissionRemoteDataSource).DTOs (Data Transfer Objects): Models that match the structure of the API response.Repository Implementations: Concrete implementations of the domain repositories.
- Location:
- Clean Architecture: Ensures separation of concerns and makes the codebase easy to test and maintain.
- BLoC for State Management: Provides a predictable and structured way to manage the UI state.
- Multi-Step Form: Guides the user through a three-step submission process (Personal Info, Skills, Review).
- Dependency Injection: Uses
get_itto manage and provide dependencies throughout the app. - Custom Networking Layer: Utilizes a local package (
network_service) for handling API requests and errors. - Centralized String Constants: All user-facing strings are managed in
lib/app/constant/constant.dartfor easy modification and future localization.
lib
├── app
│ ├── config/ # App configuration (API paths, etc.)
│ ├── constant/ # Global constants (e.g., AppStrings)
│ ├── di/ # Dependency injection setup (GetIt)
│ └── ...
│
├── features
│ └── talent_submission/
│ ├── data/ # Data layer (repositories, data sources, DTOs)
│ ├── domain/ # Domain layer (entities, use cases, repository interfaces)
│ └── presentation/ # Presentation layer (pages, BLoC, widgets)
│
└── packages
└── network_service/ # Local package for networking
- Flutter SDK (version 3.x or higher)
- Dart SDK
-
Clone the repository:
git clone <repository-url> cd talent_form
-
Get dependencies:
flutter pub get
-
Run the app:
flutter run