|
|
@ -5,7 +5,7 @@ const Token = require('markdown-it/lib/token')
|
|
|
|
const cheerio = require('cheerio')
|
|
|
|
const cheerio = require('cheerio')
|
|
|
|
|
|
|
|
|
|
|
|
const fetch = (str, tag) => {
|
|
|
|
const fetch = (str, tag) => {
|
|
|
|
const $ = cheerio.load(str, { decodeEntities: false })
|
|
|
|
const $ = cheerio.load(str, { decodeEntities: false, xmlMode: true })
|
|
|
|
if (!tag) return str
|
|
|
|
if (!tag) return str
|
|
|
|
|
|
|
|
|
|
|
|
return $(tag).html()
|
|
|
|
return $(tag).html()
|
|
|
@ -131,8 +131,8 @@ module.exports = {
|
|
|
|
test: /\.md/,
|
|
|
|
test: /\.md/,
|
|
|
|
use: [
|
|
|
|
use: [
|
|
|
|
{
|
|
|
|
{
|
|
|
|
loader: 'vue-markdown-loader',
|
|
|
|
loader: 'vue-antd-md-loader',
|
|
|
|
options: Object.assign(md, { wrapper: 'section', preventExtract: true }),
|
|
|
|
options: md,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
],
|
|
|
|
],
|
|
|
|
},
|
|
|
|
},
|
|
|
|