mdast-util-callout
v0.0.0
Published
[mdast][] extensions to **parse** [Obsidian][]-style callouts. Intended to be used with [micromark-extension-callout][].
Maintainers
Readme
mdast-util-callout
mdast extensions to parse Obsidian-style callouts. Intended to be used with micromark-extension-callout.
Since micromark-extension-callout is syntax-only, you will need to use something like unist-util-visit, to manually replace the outputted nodes in the syntax tree with ordinary markdown constructs.
Install
This package is ESM only. In Node.js (version 16+), install with npm:
npm install micromark-extension-callout mdast-util-calloutIn Deno with esm.sh:
import { calloutFromMarkdown } from "https://esm.sh/mdast-util-callout@1";In browsers with esm.sh:
<script type="module">
import { calloutFromMarkdown } from "https://esm.sh/mdast-util-callout12?bundle";
</script>API
This package exports the identifier calloutFromMarkdown.
There is no default export.
calloutFromMarkdown()
Create an extension for
mdast-util-from-markdown
to parse callout syntax in markdown.
Returns
Extension for mdast-util-from-markdown
(FromMarkdownExtension).
