I’m having some problems with performing copy+paste into Prosemirror. The following code illustrates my problem:
The result, after pasting some random HTML into the editor is that the
<h2> element is not recognized as such.
What could be wrong?
This sounds like the same problem as issue #231. Is it?
Yes I guess so. If I add another
<p> element in front, then the
<h2> is recognized correctly.
But still I find it curious, because as I understand it, a H2 element cannot exist inside a P element in HTML, .
As a user, I would expect that if I paste a block consisting of a heading followed by a paragraph (perhaps repeated a number of times), that the heading styles would be preserved.
Anyway, this is not super important for me right now. I bumped into this because of another issue.
Yes, it’s bad. That’s why the issue is still open.