title: Firebase initialization returning "Uncaught ReferenceError: firebase is not defined"
body: <p>I have the following setup:</p>
  <pre><code>&lt;button type=&quot;button&quot; name=&quot;button&quot; class=&quot;btn btn-danger&quot; onclick=&quot;signIn()&quot;&gt;
    &lt;i class=&quot;fa fa-google&quot;&gt;&lt;/i&gt; &amp;nbsp;Login With Google
  &lt;/button&gt;
  &lt;script src=&quot;js/firebase.js&quot; type=&quot;module&quot;&gt;&lt;/script&gt;
  &lt;script src=&quot;js/custom.js&quot;&gt;&lt;/script&gt;
  </code></pre>
  <p>firebase.js</p>
  <pre><code>// FIREBASE INITIALIZATION
  import { initializeApp } from &quot;https://www.gstatic.com/firebasejs/9.3.0/firebase-app.js&quot;;
  import { getAnalytics } from &quot;https://www.gstatic.com/firebasejs/9.3.0/firebase-analytics.js&quot;;
  const firebaseConfig = {
    apiKey: &quot;XXXXXXXX&quot;,
    authDomain: &quot;fir-chat-application-3e442.firebaseapp.com&quot;,
    projectId: &quot;fir-chat-application-3e442&quot;,
    storageBucket: &quot;fir-chat-application-3e442.appspot.com&quot;,
    messagingSenderId: &quot;264006913204&quot;,
    appId: &quot;XXXXXXXX&quot;,
    measurementId: &quot;XXXXXXXX&quot;
  };
  const app = initializeApp(firebaseConfig);
  const analytics = getAnalytics(app);
  </code></pre>
  <p>custom.js</p>
  <pre><code>function signIn(){
    var provider = new firebase.auth.GoogleAuthProvider();
  }
  </code></pre>
  <p>When I click on the <code>Login With Google</code> button I am getting the following error in the console:</p>
  <pre><code>Uncaught ReferenceError: firebase is not defined
  </code></pre>
  <p>I checked everything again and again but I don't seem to catch the error. What mistake am I making here?</p>