For this experience, you will go through the Get to know Firebase for Flutter Codelab and create a sample app for your personal library that documents this experience.
The Codelab starts by having you clone the Flutter codelabs repo. Then, it directs you to work in this directory, editing the files to incrementally build the working application. For this experience, we want you to instead create a GitHub repo containing your work, and this requires a few modifications to the Codelab instructions.
First, instead of doing all of the work in the flutter Codelabs repo, you will create your own personal repo to hold your work:
git clone
to obtain Flutter codelabs repo, go to https://github.com/flutter/codelabs, click the green “Code” button, and select “Download zip”.Heads Up
The analysis_options.yml file in your project consists of this line:
include: ../../analysis_options.yaml
Unfortunately, since you’ve copied the project files out of their original location, this line does not resolve correctly. To fix it, just find the analysis_options.yml file from the top level of the zip file and copy it into your project, overwriting this file.
This step involves creation and configuration of a Firebase project. You can follow those instructions as written.
It took me a while to get the Firebase CLI installed correctly. On MacOS, I needed to add $HOME/.pub-cache/bin
to my PATH (not $HOME/flutter/.pub-cache/bin
as specified in the instructions).
Follow these instructions to install packages and create the firebase_options.dart file in your project.
You can skip the section “Configure MacOS”.
I suggest that you commit and push your changes to your project at this point in the codelab, so that you have a working version to return to in case you run into problems below.
Glitch 1: queryParameters not defined
As you copy the code, you might find an error on the following line indicating that “queryParameters” is not defined.
final arguments = state.queryParameters;
This field variable was removed in go_router 10.0.0 (see Migration Guide)
As suggested in the Migration Guide, I ran dart fix --apply
and the error was removed.
Glitch 2: Podfile out of date
When I tried to run the code on the iOS simulator after making the changes in this section, I got a “podfile out of date” error. As suggested in the error message, I ran “pod repo update” inside the ios/ directory which fixed things.
Once you get to the end of this section and verify that your app handles authentication correctly, commit your working code to GitHub as a checkpoint.
I was able to follow the instructions and complete the codelab without any additional shenanigans.
I suggest you commit your code at the completion of each step just to provide a working place to return to.
By the date and time listed in the Schedule page, please upload the URL to your working GitHub repo to Laulima.