'How to merge Deltas?

I have a home application that uses an editor (currently the one from Quasar). It works great, except for a few details, notably concurrent writes.

I was looking at Quill and its Deltas, which are

(...) suitable for Operational Transform and can be used in realtime,

As the documentation describes it,

the way Deltas represent a document is by expressing the instructions starting from an empty document

I could not find anything related to the correct method to merge Deltas.

There seems to be no absolute indexing (only an index starting from an empty document), so I do not see how to merge two documents with a change each - in other words how to synchronize them at some point to replay the creation of the final document.

Is there a method for that?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source