I have a chrome extension content script running on a page. This page has a slateJs editor (a complex and highly nested contentEditable <div>).
All my extension needs to do, is take all the text inside the editor, and replace it with some custom text. How can I achieve this?
With a normal <input> , I just set the value prop and emitted an input Event on the element which did the work, but this does not seem to work.
Have also tried some complex Range and Selection manipulations, but with no success