title: Firebase 9 uploading photo
body: <p>I tried to apply photo uploading for firebase 9 with the code:</p>
  <pre><code>const uploadTask = storage.ref(`images/${image.name}`).put(image);
  </code></pre>
  <p>and:</p>
  <pre><code>            storage
                  .ref(&quot;images&quot;)
                  .child(image.name)
                  .getDownloadUrl()
                  .then(url =&gt; { 
                      // post image inside the database
                      db.collection(&quot;posts&quot;).add({ 
                          timestamp: Firebase.ServerValue.TIMESTAMP,
                          caption: caption, 
                          imageUrl: url, 
                          username: username
                      });
  
                      // set progress back to 0 once it's done! and reset everything else 
                      setProgress(0);
                      setCaption(&quot;&quot;);
                      setImage(null);
                  })
  </code></pre>
  <p>However, upon running my code, an error:
  TypeError: <em>firebase__WEBPACK_IMPORTED_MODULE_2</em>_.storage.ref is not a function</p>
  <p>How do I fix this?</p>