facebook / lexical

Lexical is an extensible text editor framework that provides excellent reliability, accessibility and performance.
https://lexical.dev
MIT License
19.95k stars 1.7k forks source link

[lexical-selection] Fix __language in null #6747

Closed ivailop7 closed 3 weeks ago

ivailop7 commented 1 month ago

5th highest error we are observing is: 'Cannot use 'in' operator to search for language in null' Not being able to reproduce, but confident the below should address this error in particular, since it seems like the only place in the code base we call 'language'

vercel[bot] commented 1 month ago

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
lexical ✅ Ready (Inspect) Visit Preview 💬 Add feedback Oct 20, 2024 10:33pm
lexical-playground ✅ Ready (Inspect) Visit Preview 💬 Add feedback Oct 20, 2024 10:33pm
github-actions[bot] commented 1 month ago

size-limit report 📦

Path Size
lexical - cjs 29.94 KB (0%)
lexical - esm 29.78 KB (0%)
@lexical/rich-text - cjs 38.51 KB (0%)
@lexical/rich-text - esm 31.58 KB (0%)
@lexical/plain-text - cjs 37.16 KB (0%)
@lexical/plain-text - esm 29 KB (0%)
@lexical/react - cjs 40.29 KB (0%)
@lexical/react - esm 33 KB (0%)
etrepum commented 1 month ago

https://github.com/facebook/lexical/issues/6701 has a repro, this will certainly fix this exception but I think another one might happen because other invariants are being violated when this occurs https://github.com/facebook/lexical/issues/6701#issuecomment-2394768062

ivailop7 commented 1 month ago

I'll rebase to latest nightly and see where things are at, before merging this one. Will keep open for a week/two.

ivailop7 commented 3 weeks ago

After rebasing to latest it's been 7 days without observing the error. This won't be needed it appears. Closing.