Why I'm getting this TRPCClient error when navigating?

While playing t3 for a future ecommerce site I noted that when navigating between routes I get this error. The data is correctly fetched but I'm wondering why is that error showing for. Even the example.hello throws it. The repo: https://github.com/esponges/t3-ecommerce. I also noted that the queries are logged everytime that the page is focused. Is that normal? Is it really refetching or it's all cached? Thanks to Theo and the mantainers for the impresive work :).
4 Replies
cornflour
cornflour3y ago
I think thats strict mode in react 18 thing, shouldnt be an issue
esponges
espongesOP3y ago
Hmm I've barely done changes to the initial boiler plate. I wonder what I may have changed.
cornflour
cornflour3y ago
oh no i meant in dev strict mode in react 18 useEffect is fired twice on mount its intended to catch common useEffect related bugs and since RQ uses useEffect under the hood i believe, it causes that fire-abort thing you saw there unless that causes some issues on your code, in which case you should fix those issue instead of trying to avoid useEffect firing twice, i dont think it is an issue
esponges
espongesOP3y ago
oh yeah, I was aware of that double useEffect in R18. And no, it does not cause —for the moment— any issue in my code. I was just curious. But thanks for you kind assitance :).
Want results from more Discord servers?
Add your server