Support MarkView.ignoreMutation #176
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "ocavue/markview-ignore-mutation"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
This PR adds
MarkView.ignoreMutation()method, similar to existingNodeView.ignoreMutation().This is useful if users want to render and update the mark view dom element based on an extra state (like React's context) without triggering prosemirror's view update.
This PR also includes some other minor updates:
ViewMutationRecord. This can reduceas anyfrom ProseMirror's code and also users' code.MarkView.ignoreMutation()andNodeView.ignoreMutation().flush(view)API for easier test.Not related to this PR, but this test case fails on my machine (macOS 15.1). It fails on both
masterbranch and my development branch.Looks good. Merged.