shelving
Version:
Toolkit for using data in JavaScript.
14 lines (13 loc) • 717 B
TypeScript
import type { JSXNode } from "../util/jsx.js";
import type { MarkupOptions } from "./util/options.js";
/**
* Parse a text string as Markdownish syntax and render it as a JSX node.
* - Syntax is not defined by this code, but by the rules supplied to it.
*
* @param input The string content possibly containing markup syntax, e.g. "This is a *bold* string.
* @param options An options object for the render.
* @param context The context to render in (defaults to `"block"`).
*
* @returns JSXNode, i.e. either a complete `JSXElement`, `null`, `undefined`, `string`, or an array of zero or more of those.
*/
export declare function renderMarkup(input: string, options: MarkupOptions, context?: string): JSXNode;