interface RepoConfig {
    enableRemoteHeadsGossiping?: boolean;
    isEphemeral?: boolean;
    network?: NetworkAdapterInterface[];
    peerId?: PeerId;
    sharePolicy?: SharePolicy;
    storage?: StorageAdapterInterface;
}

Properties

enableRemoteHeadsGossiping?: boolean

Whether to enable the experimental remote heads gossiping feature

isEphemeral?: boolean

Indicates whether other peers should persist the sync state of this peer. Sync state is only persisted for non-ephemeral peers

A list of network adapters (more can be added at runtime).

peerId?: PeerId

Our unique identifier

sharePolicy?: SharePolicy

Normal peers typically share generously with everyone (meaning we sync all our documents with all peers). A server only syncs documents that a peer explicitly requests by ID.

A storage adapter can be provided, or not