In my schema there is a node that contains meta data. The node is not visible and should not be editable/deletable by the user. Normally I would not include the meta data in the document but an external system generates files with meta data nodes that are then ingested by the prosemirror editor.
I’ve been able to make these meta data nodes read-only up to this point. But thanks to the help of @JCHollett I’ve discovered that selecting all and then deleting will remove the meta data nodes.
One solution is to completely pull the meta data out of the document before giving it to the prosemirror editor. The main reason I have not done this is that collaborative editors can make changes that update the meta data that then need to be merged into the document. Keeping the meta data in the document means the prosemirror collaborative authority takes care of that merging for me.
Is there any way to make a node completely un-editable by the user?