remark-hugo-shortcodes

Remark parser for Hugo shortcodes

Usage no npm install needed!

<script type="module">
  import remarkHugoShortcodes from 'https://cdn.skypack.dev/remark-hugo-shortcodes';
</script>

README

remark-hugo-shortcodes

Licence NPM

Remark parser & compiler for Hugo-style shortcodes.

Example

import remark from 'remark'
import { shortcodes } from 'remark-hugo-shortcodes'

const rm = remark()
    .use(shortcodes, {
        tokens: [["[[", "]]"]],
        inlineMode: true,
        markdownAttributes: ['title', 'alt', 'caption']
    })

See also