title: TypeError: firebase.storage is not a function
body: <p>Following <a href="https://firebase.google.com/docs/storage/web/create-reference#full_example" rel="noreferrer">this</a> example, I keep getting the error:</p>
  
  <pre><code> TypeError: firebase.storage is not a function
  </code></pre>
  
  <p>From this line in my code:</p>
  
  <pre><code>var storageRef = firebase.storage().ref();
  </code></pre>
  
  <p>(And when I simply try to initialize storage from the <a href="https://firebase.google.com/docs/storage/web/start" rel="noreferrer">storage guide</a>, linked from <a href="https://www.npmjs.com/package/firebase" rel="noreferrer">firebase's npm site</a>, I get the same error.)</p>
  
  <p>In my Node.js project, I'm including the following libraries:</p>
  
  <ul>
  <li><code>const firebase = require('firebase');</code></li>
  <li><code>var admin = require('firebase-admin');</code></li>
  <li><code>const fs = require('fs');</code></li>
  </ul>
  
  <p>Up to this point, I've successfully been able to read from and write to the firebase database, creating a reference to the database with <code>var db = admin.database()</code>, then <code>var ref = db.ref("/")</code>... So I know I've configured Firebase and firebase-database correctly. But I'm stuck on <code>storage</code>, and have tried both <code>admin.storage().ref()</code> and <code>firebase.storage().ref()</code>, and <code>firebase.storage().ref("/")</code> with the same error message.</p>
  
  <p>I've also tried:</p>
  
  <pre><code>var storage = firbase.storage();
  var storageRef = storage.ref();
  </code></pre>
  
  <p>and</p>
  
  <pre><code>const app = firebase.initializeApp(config);
  var storage = app.storage();
  </code></pre>
  
  <p>and with <code>ref()</code>'s void argument <code>()</code> and with <code>"/"</code>... but have the same message, yet to no avail.</p>
  
  <p>I'm using:</p>
  
  <ul>
  <li>"firebase": "^3.6.4"</li>
  <li>"firebase-admin": "^4.0.4"</li>
  <li>Node.js : v6.9.1</li>
  </ul>
  
  <p>What must I do to successfully create a reference to storage?</p>