@worldbrain/storex-sync
Version:
Offline-first syncing between multiple databases using Storex
28 lines (27 loc) • 744 B
TypeScript
import { SharedSyncLog } from '.';
import { SharedSyncLogEntry } from './types';
export interface Filesystem {
}
export declare class FilesystemSharedSyncLogStorage implements SharedSyncLog {
private fs;
private basePath;
constructor(options: {
basePath: string;
fs?: Filesystem;
});
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>;
}