I want to prevent the following behavior on a contenteditable div, because it messes with the structure if the div contains any other elements but text nodes.
I have tried the obvious:
However, this does not seem to work and I want to allow regular pasting, so disabling that is not an option.
Any help would be much appreciated. Thanks!
preventDefault on ondragover should prevent this behaviour.