UNPKG

@worldbrain/storex-sync

Version:

Offline-first syncing between multiple databases using Storex

21 lines (20 loc) 707 B
import { StorageModule, StorageModuleConfig } from '@worldbrain/storex-pattern-modules'; import { SharedSyncLog, SharedSyncLogEntry } from './types'; export declare class SharedSyncLogStorage extends StorageModule implements SharedSyncLog { getConfig(): StorageModuleConfig; createDeviceId(options: { userId: any; sharedUntil: number; }): Promise<string>; writeEntries(entries: SharedSyncLogEntry[], options: { userId: any; deviceId: any; }): Promise<void>; getUnsyncedEntries(options: { deviceId: any; }): Promise<SharedSyncLogEntry[]>; updateSharedUntil(args: { until: number; deviceId: any; }): Promise<void>; }