Using production or dev firebase app based on build mode in flutter web

Viewed 478

While developing a flutter web app, I was using the dev firebase project. Now, when the development is finished it is required to use the production firebase project for production. How can this be done other then simply swapping the firebase dev configuration from index.html with the prod firebase config before building the app. enter image description here

I tried this tutorial Dynamic HTML elements but I couldn't adapt it to my solution.

enter image description here

I thought that the configuration could be added as a child but an error was thrown:

Expected a value of type 'Element', but got one of type 'FirebaseOptions'

0 Answers
Related