Skip to content

MarkdownRenderer.render method

MarkdownRenderer › render

Official

Renders Markdown string to an HTML element.

Signature:

render(app: App, markdown: string, el: HTMLElement, sourcePath: string, component: Component): Promise<void>

Parameters:

ParameterTypeDescription
appAppA reference to the app object
markdownstringThe Markdown source code
elHTMLElementThe element to append to
sourcePathstringThe normalized path of this Markdown file, used to resolve relative internal links
componentComponentA parent component to manage the lifecycle of the rendered child components.

Returns: Promise<void>