From download to first run
This walkthrough uses the Clean + BLoC preset. Select that preset to reproduce it. Other configurations can require additional steps; the README in your download is specific to your choices.
1. Check the configuration and prerequisites
Use project name my_flutter_app, organization com.example, Clean Architecture, BLoC, Dio, GetIt, GoRouter, and no database. Install a Flutter SDK whose Dart version satisfies >=3.8.0 <4.0.0.
These are the configured template requirements, not a claim of compatibility with every SDK release. The validation record lists the SDKs and combinations previously checked.
2. Inspect the archive before running commands
Generate the ZIP, extract it, and open a terminal inside the folder containing README.md. Preview the source tree in the generator before downloading. The default configuration currently produces 22 files, including the following entry points:
lib/main.dartlib/domain/repositories/counter_repository.dartlib/data/repositories/memory_counter_repository.dartlib/features/home/state/counter_bloc.dartpubspec.yaml
3. Set up and run the starter
Keep a backup of the downloaded lib/, test/, and pubspec.yaml before creating native runners. Keep or restore those supplied files if platform generation changes them. Run these commands from the extracted project root.
flutter doctor
flutter create --org com.example --project-name my_flutter_app --platforms android,ios .
flutter pub get
flutter analyze
flutter test
flutter runflutter run lets you choose an available target. The home screen should show Counter: 0; pressing Increment once should show Counter: 1. No backend is needed for this example.
4. Understand what the included test proves
test/counter_repository_test.dart is generated with this preset:
import 'package:flutter_test/flutter_test.dart';
import 'package:my_flutter_app/data/repositories/memory_counter_repository.dart';
void main() { test('repository retains counter value', () async { final repository = MemoryCounterRepository(); expect(await repository.load(), 0); await repository.save(3); expect(await repository.load(), 3); }); }
The repository test checks the small in-memory contract. It does not prove that authentication, remote APIs, persistence, or release signing work. Add tests around your own behavior before replacing the demo repository.
5. Connect one real feature
Replace the memory repository through the application’s dependency container. Keep the screen dependent on its state owner, add an initial load and a recoverable failure state, then test a successful operation and an unavailable data source. API clients have placeholder endpoints; selecting an authentication screen does not create a real sign-in service.
Common setup problems
No supported devices or platform directory missing
The ZIP contains source, not native runners. Create the selected platforms using the README command, then start an emulator or connect a supported device. iOS development requires macOS and Xcode.
Missing .g.dart or .gr.dart file
If you selected Drift or AutoRoute, run dart run build_runner build after flutter pub get. The default BLoC preset below does not need this step.
Dependency solver failure
Compare your installed Dart version with pubspec.yaml and the selected package constraints. Preserve the first solver error and report the configuration; forcing unrelated upgrades can hide the cause.
Counter resets after restarting
The demo repository is in memory. Add persistent storage and initial loading if the value must survive a restart. Selecting a database alone does not wire the counter into it.
Choosing supported options
The form checks combinations before generation. The SQLite template targets Android, iOS, and macOS; the native Drift template excludes Web. AutoRoute and Drift add a code-generation step. Secure storage needs platform-specific setup, and Dart environment options do not create native flavors or iOS schemes.
If a combination fails, report the configuration and first error. For more context, read the source walkthrough or consult Flutter’s project creation documentation.