dalotee
DEVELOPMENT
Run Debug
flutter run --flavor dev -t lib/main.dart
Run Release
flutter run --release --flavor dev -t lib/main.dart
Build Debug
flutter build <OS> --flavor dev -t lib/main.dart
Build Release
flutter build <OS> --release --flavor dev -t lib/main.dart
PRODUCTION
Run Debug
flutter run --flavor prod -t lib/main-prod.dart
Run Release
flutter run --release --flavor prod -t lib/main-prod.dart
Build Debug
flutter build <OS> --flavor prod -t lib/main-prod.dart
Build Release
flutter build <OS> --release --flavor prod -t lib/main-prod.dart
Generating Files
Build
flutter pub run build_runner build --delete-conflicting-outputs
Watch
flutter pub run build_runner watch --delete-conflicting-outputs
Generate localization
flutter pub run intl_utils:generate
Generate icons
flutter pub run flutter_launcher_icons:main
Generate images
flutter packages pub run build_runner build
Project Structure
bloc/: Reusable blocs
commons/: mixins (loading view, post frame callback,...), helper classes
configs/: global constants, flavors, routes, IoC
data/local/: Local repositories like SharedPreferences, sqflite
data/remote/: Remote repositories
data/remote/api_service_client.dart: Define http interceptors
data/remote/api_service_helper.dart: Define base request handling
data/remote/api_service.dart: Define specific requests
data/model/: Model classes
l10n/: String values
presentation/: Presentation layer contains pages, dialogs, custom widgets,...
utils/: Utility classes like string utils, network utils, bitmap utils,...
values/: Colors, dimens, font sizes,...