Closed Epistol closed 4 years ago
Hey @Epistol As you can see in the Nuxt-Firebase Module documentation, you need to have a vuex store and the respective store actions/mutations defined in order to get "initialize" to work.
https://firebase.nuxtjs.org/guide/options/#initialize
So either setup these actions in your vuex store or set initialize to false in your nuxt-firebase config.
The documentation link provided doesn't say anything about vuex
The documentation link provided doesn't say anything about vuex
The documentation has been rebuilt last month so some stuff has been moved around, the correct link would be: https://firebase.nuxtjs.org/service-options/auth#initialize
Version
@nuxtjs/firebase: 6.1.1 firebase: 7.17.1 nuxt: 2.14.0
Reproduction Link
https://github.com/Epistol/nuxt-firebase-bug
Steps to reproduce
initAuth.js
store.commit("SET_AUTH_USER", { authUser, claims })
Go to login page
What is Expected?
Not having the error : "Uncaught (in promise) TypeError: store is undefined"
What is actually happening?
Error "Uncaught (in promise) TypeError: store is undefined"