Closed daun closed 3 months ago
Yes, you can use a data mutator to do that, these allow you to modify the raw Prosemirror data before any rendering starts. You can't really do it in an HTML mutator since by the time you get to the child the parent's HTML has already been decided.
Fantastic! I somehow thought the data mutators didn't apply here, but I'll give it a go. Thanks 🧃
Is it possible to move a node up by one level? Haven't seen an example for that in the docs and haven't found an obvious angle yet.
I'm trying to turn this:
Into this:
I managed to turn the last paragraph into a
figcaption
, but it's nested under the blockquote, and I'd like to move it up into thefigure
itself for better semantics.