Google Sign-in and Flutter Web
Getting Google Sign-in working with Flutter Web
I have a Flutter app that uses Firebase-Auth and Google Sign-in for authentication. It works on Android and iOS, so it should just work with Flutter web, right? Sadly, no. Here’s what I had to do to get it working.
The second thing was to configure the project’s OAuth consent screen on Google Cloud.
Add the client ID to the head of index.html:
Add localhost for Local Development
Run From the Command Line
Now we can run our app:
Edit the URL in the Browser
If you see
[::1]:5000 in your browser’s URL, change it to
localhost:5000 and all should work.
Leave a comment