I need a simple extension that deletes all divs (with any ID or class).
Extension should be running in WP text editor, so I’m using
textEditor.value = textEditor.value
I guess it should use .replaceAll, but I’m not sure how to word expression to delete all divs and ignore their ID and class. Both ID and class should be deleted also.
Example:
<div id="example1" class="example2">Text</div>
Should be just:
<p>Text<p>