You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Bug: Editor constantly loses focus in React 17 #2959
When using ReactDOM.render (React 18 & 17), Having many Lexical editors with key= attributes, causes editors to lose focus in a way that becomes unusable.
This bug did not occur in Lexical 3.11 and seems to have been introduced with this commit.
I have an internal UI that's used to develop lexical that looks like this, as you're typing in the top left editor, I have a few other lexical instances with key= attributes that I forcefully re-create to ensure their instantiated with the value of the primary editor. This allows me to verify rendering is consistent across different scenarios
When trying to upgrade to the latest version, I noticed typing on this page stopped working, after a few hours of debugging, I narrowed it down the ReactDOM method. 🧐
The offending commit doesn't have anything that sticks out to me, but when trying my repro on the commit before it, things worked as expected, and fail afterwards.
Activity
[-]Bug: Editor constantly loses focus[/-][+]Bug: Editor constantly loses focus in React 17[/+]trueadm commentedon Sep 8, 2022
Thanks for the detailed repro report. I found the issue and the fix should be in #2967