a starter template for flutter/firebase/riverpod/hooks/gorouter/flavors/theming/icons/launchscreen
-
mason add jack
-
mason make jack
- in your new app dir
- if you don't have flutterfire yet run
dart pub global activate flutterfire_cli
- if you don't have flutterfire yet run
chmod +x flutterfire_config_flavors.sh
./flutterfire_config_flavors <Firebase-Project-ID> <Firebase-Account-Email (optional)>
only add account email parameter if you need to specify firebase account
*steps 2 and 3 are optional
- Go to firebase console of project that you created (or existed)
- Setup auth (enable anonymous sign in)
- cloud firestore
- storage
- anything you need.. etc
- in firebase dir choose same project in previous step
firebase init
- Change the Icons in the assets directory based off of the examples i have. keep the filenames the same and they have their corresponding flavor.
<your-app-dir>
└───assets
│ icon.png
│ icon-dev.png
│ icon-local.png
│ foreground.png
- in rename the .env_config file to .env and edit to your flavor colors
LOCAL_COLOR='"#FFFFFF"'
DEV_COLOR='"#000000"'
PROD_COLOR='"#180437"'
chmod +x icons_and_launch_screen.sh
./icons_and_launch_screen.sh
For theming this uses the dynamic_color package but when the device isn't supported it uses some themes found in <your-app-dir>/lib/theming/themes.dart
The defaultLightColorScheme
and defaultDarkColorScheme
can be generated using the Material 3 Theme Builder
Then all you have to do is export to flutter and replace the code in app/lib/theming/themes.dart
.