Replies: 1 comment
-
Damn I found the difference: const documents = snapshot.docs
.map(doc => {
return doc.data();
})
.filter(val => val != null); |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi,
mostly I'm using onSnapshot in my application. There I had no problems with withConverter until now.
For example:
Here
setMyData
expects an SetStateAction<MyDataType[]> (react state) and it works.Now I want to do a seperate get somewhere else:
But the result here does not match. Typescript says it is :
QueryDocumentSnapshot<MyDataType>[]
How can I get the correct response type?
Beta Was this translation helpful? Give feedback.
All reactions