UNPKG

alinea

Version:

[![npm](https://img.shields.io/npm/v/alinea.svg)](https://npmjs.org/package/alinea) [![install size](https://packagephobia.com/badge?p=alinea)](https://packagephobia.com/result?p=alinea)

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