Applies delta update generated by the remote document replica to a current document. This
method assumes that a payload maintains lib0 v1 encoding format.
Applies delta update generated by the remote document replica to a current document. This
method assumes that a payload maintains lib0 v2 encoding format.
Converts a sticky index (see: createStickyIndexFromType
) into an object
containing human-readable index.
Retrieves a sticky index corresponding to a given human-readable index
pointing into
the shared ytype
. Unlike standard indexes sticky indexes enables to track
the location inside of a shared y-types, even in the face of concurrent updates.
Returns a string dump representation of a given update
encoded using lib0 v1 encoding.
Returns a string dump representation of a given update
encoded using lib0 v2 encoding.
Deserializes sticky index serialized previously by encodeStickyIndex
.
Encodes all updates that have happened since a given version vector
into a compact delta
representation using lib0 v1 encoding. If vector
parameter has not been provided, generated
delta payload will contain all changes of a current ywasm document, working effectivelly as its
state snapshot.
Encodes all updates that have happened since a given version vector
into a compact delta
representation using lib0 v2 encoding. If vector
parameter has not been provided, generated
delta payload will contain all changes of a current ywasm document, working effectivelly as its
state snapshot.
Encodes a state vector of a given ywasm document into its binary representation using lib0 v1
encoding. State vector is a compact representation of updates performed on a given document and
can be used by encode_state_as_update
on remote peer to generate a delta update payload to
synchronize changes between peers.
Serializes sticky index created by createStickyIndexFromType
into a binary
payload.
When called will call console log errors whenever internal panic is called from within
WebAssembly module.