react-md-editor
react-md-editor copied to clipboard
Deleting <blockquote> in Editor causes Preview Error: NotFoundError - Failed to execute 'removeChild'
First, thank you for developing this highly appreciated editor!
I tried to embed SNS quote cards such as Twitter (X), Instagram, and Bluesky using <blockquote> and then
NotFoundError: Failed to execute 'removeChild' on 'Node': The node to be removed is not a child of this node.
I think that when I delete the <blockquote> in the editor, it affects the DOM tree, but it does not update the Previewer's React tree accordingly. It seems possible to address this with onChange in MDEditor, but I would like a more fundamental solution. What is the best practice to avoid this error?
@skyfoliage Would disabling the script tag solve the issue?
<MDEditor
previewOptions={{
+ disallowedElements: ['script'],
}}
/>
@jaywcjlove Thanks, I'll give it a try :)