Skip to content

MarkdownRenderer.renderMarkdown method

MarkdownRenderer › renderMarkdown

Official

Renders Markdown string to an HTML element.

Signature:

renderMarkdown(markdown: string, el: HTMLElement, sourcePath: string, component: Component): Promise<void>

Parameters:

ParameterTypeDescription
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>

Since: 0.10.6