-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Fix clear rootElement on React #6389
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
size-limit report 📦
|
@@ -1011,7 +1011,7 @@ describe('LexicalEditor tests', () => { | |||
await Promise.resolve().then(); | |||
}); | |||
|
|||
expect(listener).toHaveBeenCalledTimes(3); | |||
expect(listener).toHaveBeenCalledTimes(4); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No idea why it's calling the listener one more time with the HTML reference, and for some reason the useEffect without dependencies will also be unmounted defeating the purpose of this test. If anyone knows more about ReactTestUtils.act
I'm all ears
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
When we introduced the
if
condition in #5070 we missed thenull
case.