Class ObjNode<Value>

Represents a obj JSON CRDT node, which is a Last-write-wins (LWW) object. It is a map of string keys to LWW registers. The value of each register is a reference to another JSON CRDT node.

Type Parameters

Implements

Constructors

Properties

Methods

Constructors

Properties

Unique ID within a document.

Methods

  • Retrieves a JSON CRDT node at the given key.

    Type Parameters

    • K extends string | number | symbol

    Parameters

    • key: K

      A key of the object.

    Returns undefined | Value[K]

    JSON CRDT node at the given key, if any.

  • Iterate over all key-value pairs in the object.

    Parameters

    • callback: ((node, key) => void)

      Callback to call for each key-value pair.

        • (node, key): void
        • Parameters

          Returns void

    Returns void