UNPKG

alinea

Version:
12 lines (11 loc) 427 B
import * as Y from 'yjs'; import type { Entry } from './Entry.js'; import { Type } from './Type.js'; export declare const DOC_KEY = "#root"; export declare function createYDoc(type: Type, entry: Entry | null): Y.Doc; export declare function applyEntryData(doc: Y.Doc, type: Type, entry: Entry): void; export declare function parseYDoc(type: Type, doc: Y.Doc): { path: any; title: any; data: Record<string, any>; };