Flutter App Setup Guide
Welcome to the fixmate mobile application documentation. This guide will help you set up, customize, and build the Flutter app for Android and iOS.
1. Project Setup
Follow these steps to initialize the project:
- Unzip the
fixmate_appsource code. - Open the project folder in your IDE (VS Code or Android Studio).
- Open a terminal in the project root and run the following command to install dependencies:
flutter pub get
Running the App
To run the app on a connected device or emulator:
- Connect your Android device (enable USB Debugging) or start an iOS Simulator / Android Emulator.
- Run the following command:
flutter run
You can also press F5 in VS Code or click the Run button in Android Studio.
2. API Configuration
Before building the app, you must connect it to your hosted backend server.
- Navigate to
lib/config/app_config.dart. - Update the
baseUrlvariable with your backend domain (e.g.,https://api.yourdomain.com/api).
// lib/config/app_config.dart
class AppConfig {
// Replace with your actual domain (MUST use https://)
static const String baseUrl = 'https://your-api-domain.com/api';
...
}
How to Configure your Server URL:
- Production: Use your registered domain with an SSL certificate (e.g.,
https://api.myapp.com/api). - Local Testing (Android): Use
https://10.0.2.2:8000/apiif using a local Laravel server with SSL proxy (like Ngrok). - Local Testing (iOS): Use your computer's local IP address with HTTPS.
3. Branding & Customization
Change App Name
To change the display name of the app:
- Open
lib/config/app_config.dartand update theappNamevariable. - Run the following command to update native configuration files:
flutter pub run rename_app:main all="Your New App Name"
Note: You may need to add rename_app to your
pubspec.yaml or update AndroidManifest.xml and
Info.plist manually if you prefer.
Change Package Name
To change the package name (Bundle ID), we recommend using the
change_app_package_name package (included or install it globally):
flutter pub run change_app_package_name:main com.yourcompany.appname
Change App Logo
The app uses flutter_launcher_icons to generate app icons.
- Replace the logo file at
assets/images/logo.pngwith your own (recommended size: 1024x1024px). - Open
pubspec.yamland verify the configuration:
flutter_launcher_icons:
android: "launcher_icon"
ios: true
image_path: "assets/images/logo.png"
...
3. Run the valid command to generate the icons:
flutter pub run flutter_launcher_icons
Change App Colors
To change the primary theme color:
- Open
lib/config/app_config.dart. - Update the
primaryColorvariable.
// lib/config/app_config.dart
class AppConfig {
...
static const Color primaryColor = Color(0xFFC04F18); // Change hex code here
...
}
Homepage Layouts
The app comes with 4 pre-built homepage designs. You can toggle between them instantly by updating the homeLayout constant.
| Variant | Style | Description |
|---|---|---|
HomeLayout.v1 |
Standard | Classic grid of categories with a vertical list of services. |
HomeLayout.v2 |
Modern | Card-based design with horizontal scrolling sections. |
HomeLayout.v3 |
Minimalist | Clean, search-focused layout with generous white space. |
HomeLayout.v4 |
Dynamic | Default. Premium dashboard with banners, promotions, and rich interactive cards. |
To switch layouts, open lib/config/app_config.dart and change the following line:
static const HomeLayout homeLayout = HomeLayout.v4; // Change to v1, v2, or v3
Basic Project Edits
Common customizations for your project:
- Images & Assets: Replace existing images in the
assets/images/folder. Ensure filenames remain the same or update references in the code. - Texts & Translations: Edit text strings in the
lib/l10n/directory (for multi-language support) or checklib/constants/if hardcoded. - Onboarding Screens: content is often found in
lib/screens/onboarding/or configured vialib/config/.
4. Build & Deploy
Once you are ready to publish, use the following commands to build the release artifacts.
Android (APK & App Bundle)
# Build APK
flutter build apk --release
# Build App Bundle (AAB) for Play Store
flutter build appbundle --release
iOS (IPA)
# Build IPA for App Store
flutter build ipa --release
You can find the generated files in the build/app/outputs/flutter-apk/ (Android)
or verify the archive in Xcode (iOS).