Y-prosemirror - Mapping a single relative position when doc changes

Hi @jamisOn,

More about relative positions here: Y.RelativePosition - Yjs Docs

You probably already found how we use relative positions in ProseMirror. There are functions in y-prosemirror that allow you to transform a relative position from & to an absolute position. The idea is that you create a relative position (which is basically pointing at a specific character in the document), then somebody can make changes to the document which will trigger a ProseMirror transaction, then you need to transform the relative position again back to an absolute position using the updated state. Relative positions will make sure that the position still points to the original character and adjusts the position accordingly to the applied change. But it is important that you recompute the absolute position on every change (local and remote ones).