• Generate a sync message to send to the peer represented by inState

    Returns

    An array of [newSyncState, syncMessage | null] where newSyncState should replace inState and syncMessage should be sent to the peer if it is not null. If syncMessage is null then we are up to date.

    Type Parameters

    • T

    Parameters

    • doc: Doc<T>

      The doc to generate messages about

    • inState: SyncState

      The SyncState representing the peer we are talking to

    Returns [SyncState, SyncMessage | null]

Generated using TypeDoc