utils from api.useContext() not working?
Anyone know why utils from api.useContext() is not working. I cannot see any of my routers. I have restarted my TS server, still nothing. Is there some kind of setup I need to do to access this? I am trying to get the data from cache from one of my queries here, similar to this other screenshot from T3 docs: https://create.t3.gg/en/usage/trpc#-utilsapits . Is there any docs or examples that any of you suggest I read up on? Thanks in advance.
1 Reply
For anyone who ran into a similar problem, dont name your router client, it conflicts with the stuff inside api.useContext(), renaming my router to clients fixed this issue.