nuxt-community / firebase-module

🔥 Easily integrate Firebase into your Nuxt project. 🔥
https://firebase.nuxtjs.org
MIT License
641 stars 99 forks source link

auth.addAuthTokenListener is not a function #553

Closed uppergoal closed 3 years ago

uppergoal commented 3 years ago

Version

"@nuxtjs/firebase": "^7.6.1", "firebase": "^8.6.7", "nuxt": "^2.15.6",

Steps to reproduce

in nuxt.config services: { auth: { initialize: { onAuthStateChangedAction: 'auth/onAuthStateChanged', }, disableEmulatorWarnings: true, emulatorHost: isDev && useEmulators ? 'http://localhost' : undefined, emulatorPort: isDev && useEmulators ? 9099 : undefined, }, firestore: { emulatorPort: isDev && useEmulators ? 8080 : undefined, emulatorHost: isDev && useEmulators ? 'localhost' : undefined, }, database: { emulatorPort: isDev && useEmulators ? 9000 : undefined, emulatorHost: isDev && useEmulators ? 'localhost' : undefined, }, messaging: { createServiceWorker: true, fcmPublicVapidKey: '', }, storage: true, },

What is Expected?

App working

What is actually happening?

Error: e.auth.addAuthTokenListener is not a function When I'm removing the services.database, everything works fine

lupas commented 3 years ago

Duplicate of: https://github.com/nuxt-community/firebase-module/issues/550

Please downgrade Firebase to "firebase": "8.6.5" and try again, the newest v8.6.7 seemed to have introduced this bug. I assume they will fix it in the next update.

uppergoal commented 3 years ago

Sorry for the duplicated issue and thanks for your quick reply. The error is still there with firebase v8.6.5