lexical icon indicating copy to clipboard operation
lexical copied to clipboard

Feature: Editor within Custom Element Shadow DOM

Open johnstonmatt opened this issue 11 months ago • 1 comments

I would like to be able to instantiate a lexical editor bound to an element within a Shadow DOM. When lexical is configured in this way it fails to properly process updates to that element's contents. I believe that the project has a huge opportunity here, maybe even something like a <lexical-composer> custom element, bringing the vanilla DX closer to React's.

I am happy to implement my own editor as a user as well of course, but that requires a fix for processing updates to the editor element contents in a ShadowRoot.

johnstonmatt avatar Aug 09 '23 04:08 johnstonmatt

Hi! Can you provide some code sandbox (e.g. fork https://stackblitz.com/github/facebook/lexical/tree/main/examples/vanilla-js?file=src%2Fmain.ts) with an example of the issue?

If you do, it will help a lot with resolution ;)

StyleT avatar Apr 05 '24 22:04 StyleT