Firebase issue in Vuejs3/vite

Here i installed firebase on my projects but showing me this error on browser console

3SIvh

I changed versions of firebase and used CDN but still not working and also tried to implement via official document .

Code:-

import 'firebase/auth';
import 'firebase/database';

const database = {
  apiKey: "",
  authDomain: "",
  databaseURL: "",
  projectId: "",
  storageBucket: "",
  messagingSenderId: ""
};

const firebaseApp = initializeApp(database);

  var user_id = localStorage.getItem("user_id");
      console.log(user_id);
      var unreadmsgcnt = firebaseApp
        .database()
        .ref()
        .child(this.firebase)
        .child(user_id)
        .child("unreadMessageCount");
      unreadmsgcnt.set(0);

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.