skip to Main Content

I want to link up Google Cloud Firebase to my web app. In this tutorial, I see these seven arguments passed to initializeApp. The narrator says they are available in the Google Cloud Console:

enter image description here

My question is, um, where in the console? I just don’t see it:

enter image description here

Where am I supposed to be looking? Or is there a CLI command to reveal these arguments?

2

Answers


  1. It’s very confusing.

    Firebase is a Google acquisition and though well-integrated, there remain differences.

    The Google Cloud console: https://console.cloud.google.com

    The Firebase console: https://console.firebase.google.com

    You want to select "Project settings":

    Project settings

    And the values you need are presented on that page.

    Login or Signup to reply.
    1. Go to the Firebase Console.
    2. Select your project from the top navigation bar.
    3. Click on the gear icon next to "Project Overview" in the sidebar.
    4. Click on "Project settings".
    5. Scroll down to the "Your apps" section.
    6. Click on the three dots next to your web app and select "Config".

    In this config section, you’ll find the seven arguments:

    1. apiKey
    2. authDomain
    3. projectId
    4. storageBucket
    5. messagingSenderId
    6. appId
    7. measurementId

    Alternatively, you can also find these values in the Firebase CLI by running the command:

    firebase projects:get-config
    Replace with your actual project ID.

    These values are used to initialize the Firebase app in your web application, like so:

    firebase.initializeApp({
      apiKey: '<API_KEY>',
      authDomain: '<AUTH_DOMAIN>',
      projectId: '<PROJECT_ID>',
      storageBucket: '<STORAGE_BUCKET>',
      messagingSenderId: '<MESSAGING_SENDER_ID>',
      appId: '<APP_ID>',
      measurementId: '<MEASUREMENT_ID>'
    });
    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search