UNPKG

medium-proeditor

Version:

A powerful & customizable Medium-style rich text editor

28 lines 743 B
import { type Schema } from 'prosemirror-model'; import type { GetHTMLOptions, JSONContent } from '../types'; /** * Generates published HTML from a JSON document. * * @param doc - The JSON document content. * @param schema - The built schema. * @returns The generated HTML. * @example * const doc = { * type: 'doc', * content: [ * { * type: 'paragraph', * content: [ * { * type: 'text', * text: 'Hello world!' * } * ] * } * ] * } * const schema = buildSchema() * const html = generateHTML(doc, schema) */ export declare function generateHTML(doc: JSONContent, schema: Schema, options: GetHTMLOptions): string; //# sourceMappingURL=generateHTML.d.ts.map