markdown-it-mdc
v0.2.5
Published
Markdown Components (MDC) support for markdown-it
Downloads
12,315
Readme
markdown-it-mdc
MDC (Markdown Components) for markdown-it
.
Use VS Code MDC Extension for IDE support.
Usage
npm i markdown-it markdown-it-mdc
import MarkdownIt from 'markdown-it'
import pluginMdc from 'markdown-it-mdc'
const md = new MarkdownIt()
.use(pluginMdc)
const result = md.render(`
# Hello
Hello **World** with :my-component{.text-red name="foo"}!
`)
Features
This plugin implements all the syntaxes documented in MDC Syntax. We are still testing behavior compatibility in detail before reaching v0.1.0
.
- [x] Block Component
- [x] Nesting
- [x] YAML Props
- [x] Slots
- [x] Inline Components
- [x] Inline Props
- [x] Span
- ~~Frontmatter~~. Frontmatter is not built-in in this plugin, we recommend using
@mdit-vue/plugin-frontmatter
instead.
Sponsors
License
MIT License © 2022 Anthony Fu