T
tRPC

❓-help

getInfiniteData returns undefined

Ddavidgonmar4/19/2023
I am using the t3-stack. Whenever I am calling getInfiniteData it returns undefined.
console.log(
trpc.events.getAll.getInfiniteData()
)
console.log(
trpc.events.getAll.getInfiniteData()
)
There is data, according to the React Query Devtools, so thats not the problem Would love some help:)
Nnlucas4/19/2023
So getInfiniteData probably returns a promise, printing that in a console log seems like it won't give you what you want? Are you awaiting it in reality?

Looking for more? Join the community!