I am trying to fix an issue with an old firebase app. and im trying to update the app to 8. I dont want to use 9 yet because i want to use the old code as much as possible. With that in mind everything is in an html page. And when I import the new libraries I get:
Uncaught TypeError: Failed to resolve module specifier “firebase/app”. Relative references must start with either “/”, “./”, or “../”.
But this is pretty much exactly as the tutorial asks me to implement the code. I looked at other SO’s here but its all for the firebase 9 syntax, but specifically, I want to use the 8 namespaced syntax.
<script src="/__/firebase/8.10.1/firebase-app.js"></script>
<script src="/__/firebase/8.10.1/firebase-auth.js"></script>
<script src="/__/firebase/8.10.1/firebase-storage.js"></script>
<script src="/__/firebase/8.10.1/firebase-database.js"></script>
<script type="module">
import firebase from "firebase/app";
// Add Firebase products that you want to use
import "firebase/auth";
import "firebase/storage";
import "firebase/database";