Closed FlorianChretien closed 5 years ago
if you put the data from the store in data, it will take the initial value (empty array). Use a computed property instead:
computed: {
todos () {
return this.$store.todos
}
}
(you should check vuex docs 😛 )
I tried otherwise and it still does not work ....: '( Thank you for your help!
(Yet it works with viewfire)
store
component
TypeError : "document.onSnapshot is not a function"
Something tell me that it's à problem with the firebase ref syntax. Did you try firebase. Database().Ref('utilisateurs')
Also what db do you use just to be sure and are you using the corresponding version of vuexfire?
Hi! Thank you for your response @aspben. I use the following list :
If I try to replace .ref with .collection I will make an error .. :/ "_services_firebase_firebase__WEBPACK_IMPORTED_MODULE_6__.db.collection is not a function"
It's a base for me that works if I use vuefire. My config :
I just checked. On my project the version is alpha-9 and I use firestore. Im not sure vuexfire work for both database. Maybe check into that.
vuefire < 2 is for the RTDB, vuexfire > 3 and vuefire > 2 are for Firestore. In the future, newer versions will support both versions but right now it doesn't
Yes my bad ! 😄 Thanks toi very much @aspben @posva
Hello,
Sorry to bother you but I am stuck for many days without moving forward ... Can not make the example work ...
Do you have a track? See the solution? I searched everything but I can not find ... Really sorry for this idiot question :/
thanks
store
component
(VueCli with VueRouter, Vuex, Webpack ...)