Paddy
Paddy11mo ago

tRPC won't return route with function, only JSON

Hey all, Why can I go to route 'test' and the 'This is a test!' is being returned, but when I try to go to another router called 'posts' it returns this big error, 404, meaning that it doesn't even exist, right? While the function does exist, what is it exactly looking for what I don't have? Would love to hear from someone! 🙂 Best regards.
No description
No description
No description
4 Replies
Nick
Nick11mo ago
Probably because posts is a router and not a procedure, what procedures does it have on it?
Paddy
PaddyOP11mo ago
Hey @Nick Lucas Thank you so much for your reply, I couldn't reply earlier, sorry. I atteched two screenshots, hopefully this gives you an idea of what it has, please let me know if this is what you asked.
No description
No description
Nick
Nick11mo ago
So it's posts.getPosts then?
Paddy
PaddyOP11mo ago
Yes, haha, thank you!