diff --git a/docs/.vuepress/config.js b/docs/.vuepress/config.js index a6756baa7..1bc13cdac 100644 --- a/docs/.vuepress/config.js +++ b/docs/.vuepress/config.js @@ -63,6 +63,16 @@ if (deprecatedRules.length > 0) { } module.exports = { + configureWebpack (_config, _isServer) { + return { + resolve: { + alias: { + module: require.resolve('./shim/module') + } + } + } + }, + base: '/', title: 'eslint-plugin-vue', description: 'Official ESLint plugin for Vue.js', diff --git a/docs/.vuepress/shim/module.js b/docs/.vuepress/shim/module.js new file mode 100644 index 000000000..66ab9785e --- /dev/null +++ b/docs/.vuepress/shim/module.js @@ -0,0 +1,3 @@ +module.exports = { + createRequire: () => () => null +} diff --git a/docs/rules/comment-directive.md b/docs/rules/comment-directive.md index 7ff91450c..33ad1fa9d 100644 --- a/docs/rules/comment-directive.md +++ b/docs/rules/comment-directive.md @@ -9,7 +9,7 @@ description: support comment-directives in `