transform.HTMLToMarkdown
Returns the given HTML converted to Markdown.
- Syntax
- transform.HTMLToMarkdown INPUT
- Returns
- string
This function is experimental and its API may change in the future.
The transform.HTMLToMarkdown function converts HTML to Markdown by utilizing the html-to-markdown Go package.
Usage
{{ .Content | transform.HTMLToMarkdown | safeHTML }}Plugins
The conversion process is enabled by the following html-to-markdown plugins:
| Plugin | Description |
|---|---|
| Base | Implements basic shared functionality |
| CommonMark | Implements Markdown according to the Commonmark specification |
| Table | Implements tables according to the GitHub Flavored Markdown specification |
Last updated:
September 11, 2026
:
content: Comply with function/method description guidance in style guide (76fa3fc9e)
Improve this page