-
-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Infinite loop (browser crashes) in Next 13 #5532
Comments
please show a runnable reproduction of your issue, or we'll close this issue. |
I don't have an example right now but this is the code. Not sure how to format properly here. If I use the same code in a normal react app, it works. So I assume it must be related to Next.
|
then please create one? Put that code in a codesandbox, and stub out the api request with a It's your job to provide a proper reproduction if you want help from maintainers. There are a ton of things missing that could be done wrongly, like queryClient creation etc. From seeing just that code, I'd say things are fine and it works on my machine ... |
Here you go: https://codesandbox.io/p/sandbox/kind-snow-04rdx0 |
Idk but that's exactly the reason why I always demand a reproduction. It's 95% not the libs fault, but something in your surroundings. |
I migrated back to Next 12.3.2 and it works just fine. Must have been the latest version from Next. |
I don't think you can have client components using the 'async' keyword: facebook/react#26801 |
good catch! |
Describe the bug
Can't get React Query to work in Next 13 (even on client components). The app crashes totally and if I log the query it's basically looped indefinitely.
Your minimal, reproducible example
Code
Steps to reproduce
Expected behavior
It should not loop nor crash. or
How often does this bug happen?
Every time
Screenshots or Videos
No response
Platform
Windows, Chrome
Tanstack Query adapter
react-query
TanStack Query version
v4.29.12
TypeScript version
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: