remark plugin to support ruby syntax of DenDenMarkdown(https://conv.denshochan.com/markdown)
npm install remark-denden-rubyremark plugin to support ruby syntax of denden markdown.
``sh`Of course you can use npm, yarn or other tools.
pnpm add remark-denden-ruby
ESM only.
`js
import { unified } from "unified";
import remarkParse from "remark-parse";
import remarkRehype from "remark-rehype";
import rehypeStringify from "rehype-stringify";
import remarkRuby from "remark-denden-ruby";
const md2html = (md) => {
const result = unified()
.use(remarkParse)
.use(remarkRuby)
.use(remarkRehype)
.use(rehypeStringify)
.processSync(md);
return result.toString();
};
const markdown =
{幻想殺し|イマジンブレイカー};
console.log(md2html(markdown));
`
The result is:
`html`
幻想殺し
Escaping like \{Info\|Warning\}` is not supported due to technical reason. You can use inline code instead.