I want to get all documents from firestore. I tried to do this
const firestore = getFirestore()
firestore
.collection('products')
.limit(4)
.get()
.then((snapshot) => {
dispatch({ type: 'SHOW', snapshot })
})
.catch((err) => {
dispatch({ type: 'SHOW_ERROR', err })
})
then i do this
case 'SHOW':
console.log('SHow 4', action.snapshot.docs)
but as response i get this enter image description here How can i get the values of objects?