so I am working on a project using firebase and the version I have downloaded is 9.8.3 (which iirc is the most current version). However, I am receiving an error message that reads
ERROR in ./src/firebase.js 16:20-42 export 'default' (imported as 'firebase') was not found in 'firebase/compat/app' (module has no exports)
and while I am certain that I am exporting it incorrectly I am not sure what I am doing wrong. Here is what my current 'firebase.js' file looks like:
// For Firebase JS SDK v7.20.0 and later, measurementId is optional
import firebase from 'firebase/compat/app';
import 'firebase/compat/auth';
import 'firebase/compat/firestore';
const firebaseConfig = {
apiKey: "AIzaSyCx0tcar2EmnD2tGQ3CjNDy3-Tf363YiPM",
authDomain: "starvana2-9d9db.firebaseapp.com",
projectId: "starvana2-9d9db",
storageBucket: "starvana2-9d9db.appspot.com",
messagingSenderId: "508991125201",
appId: "1:508991125201:web:8f4b5c7fbf718fb4db77f0",
measurementId: "G-7S7H73K4HL"
};
const firebaseApp = firebase.initializeApp(firebaseConfig);
const db = firebaseApp.fireStore();
const auth = firebase.auth();
export { db, auth,};
export default firebase;
Can someone look over it and explain what the issue is? I would be super grateful!