chenjiahan 6a054ca0e3 Revert "chore: remove @vant/markdown-loader package"
This reverts commit 6eec7f3c2f9207227c178baedf767f3031e040f8.
2021-09-30 10:32:29 +08:00

15 lines
329 B
JavaScript

const MarkdownIt = require('markdown-it');
const markdownItAnchor = require('markdown-it-anchor');
const highlight = require('./highlight');
const { slugify } = require('transliteration');
const parser = new MarkdownIt({
html: true,
highlight,
}).use(markdownItAnchor, {
level: 2,
slugify,
});
module.exports = parser;