import type { Root } from 'mdast'; /** Old source + its parsed tree, threaded across reactive updates. */ export interface ParseCache { readonly source: string; readonly root: Root; } /** Result of one (incremental or full) parse: the tree plus the cache to thread * into the next update. `reused` is the number of prefix blocks reused (0 = full * parse) — used only for dev diagnostics. */ export interface IncrementalResult { readonly root: Root; readonly cache: ParseCache; readonly reused: number; } /** Parse `source` incrementally against `cache` (the previous source + tree), or * fully when no safe reuse boundary exists. The returned tree is structurally * identical to `parse(source)` — reuse only ever changes which node OBJECTS are * shared with the previous tree (so their keys, and thus their DOM, survive). */ export declare function incrementalParse(cache: ParseCache | undefined, source: string, parse: (src: string) => Root, allowPrefixReuse?: boolean): IncrementalResult; //# sourceMappingURL=incremental.d.ts.map