-
Notifications
You must be signed in to change notification settings - Fork 45
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
Disabling the warning in 16.8 #5
Comments
Why don't you use 16.9 alpha version? The |
I definitely agree that 16.9 would have been ideal. There's of course some circumstances specific to my project (although it can't be that rare) that factors in:
|
I would say this is more of the scarecrow that a real issue. React is very stable and "alpha" doesn't mean "it's broken", but "there are some new things we want users to check out before rolling out" instead. I would even say it's intentional to test these releases in production. Imagine there is a bug that gets revealed only in your code. The "stable" 16.9 comes out, you will use it and bam, bug hits you anyway. Furthermore, I believe that particular release is focused on Alternatively, you can try |
So is there no way to just disable the "You've caused a rerender outside of act()" warning with no other effects? |
AFAIK there is no such thing as it would be too tempting to just disable instead of fixing the situation :) |
@aravindet does |
@threepointone that might work, thanks! They are already hijacking the console to add the "fail CI on output" behaviour, but I think I can double-hijack it during my tests 👍 |
Hi Sunil! 😄
I know this is a somewhat annoying ask, but is there a good way to suppress the
act()
warning until 16.9 is released?(The code I'm testing ends up creating a chain of promises, which Jest's fake timers won't run synchronously until this is merged.)
The text was updated successfully, but these errors were encountered: