You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I confirm that this is a issue rather than a question.
Bug report
Version
Steps to reproduce
in config.js define:
markdown: {
extendMarkdown: md => {
md.use(require('markdown-it-container'),
'card', {
validate: function (params) {
return params.trim().match(/^card\s+(.*)$/);
},
render: function (tokens, idx) {
var m = tokens[idx].info.trim().match(/^card\s+(.*)$/);
if (tokens[idx].nesting === 1) {
return '<div class="card custom-block"><p class="custom-block-title">' + md.utils.escapeHtml(m[1]) + '</p>\n';
} else {
return '</div>\n';
}
}
})
}
}
What is expected?
A custom container to be used.
What is actually happening?
An error:
Error: Cannot find module 'markdown-it-container'
at Function.Module._resolveFilename (module.js:557:15)
at Function.Module._load (module.js:484:25)
at Module.require (module.js:606:17)
at require (internal/module.js:11:18)
at extendMarkdown (/docs/.vuepress/config.js:63:14)
at afterInstantiate (/usr/local/lib/node_modules/vuepress/node_modules/@vuepress/core/lib/prepare/createMarkdown.js:23:23)
at module.exports (/usr/local/lib/node_modules/vuepress/node_modules/@vuepress/markdown/index.js:116:23)
at module.exports (/usr/local/lib/node_modules/vuepress/node_modules/@vuepress/core/lib/prepare/createMarkdown.js:27:10)
at AppContext.process (/usr/local/lib/node_modules/vuepress/node_modules/@vuepress/core/lib/prepare/AppContext.js:104:21)
at <anonymous>
at process._tickCallback (internal/process/next_tick.js:118:7)
Other relevant information
Your OS: MacOS X Mojave
Node.js version: v9.7.1
Browser version: latest
Is this a global or local install? global install
Which package manager did you use for the install? NPM
The text was updated successfully, but these errors were encountered:
Bug report
Version
Steps to reproduce
in config.js define:
What is expected?
A custom container to be used.
What is actually happening?
An error:
Other relevant information
The text was updated successfully, but these errors were encountered: