Warm tip: This article is reproduced from serverfault.com, please click

其他-TypeError:使用 VuePress 时 node.getIterator 不是函数

(其他 - TypeError: node.getIterator is not a function when using VuePress)

发布于 2021-06-23 09:39:58

我正在关注https://v1.vuepress.vuejs.org/guide/getting-started.html#quick-start来生成一个新的 VuePress 站点。我做了以下事情(我使用的是 Node 15.4.0):

npx create-vuepress-site
cd docs
npm install
npm run build

我越来越:

TypeError: node.getIterator is not a function at LazyResult.visitTick (/home/marcin/tmp/vuepress-testing/docs/node_modules/optimize-css-assets-webpack-plugin/node_modules/postcss/lib/lazy-result.js :528:33) 在 LazyResult.runAsync (/home/marcin/tmp/vuepress-testing/docs/node_modules/optimize-css-assets-webpack-plugin/node_modules/postcss/lib/lazy-result.js:408:30 ) 在 LazyResult 的 LazyResult.async (/home/marcin/tmp/vuepress-testing/docs/node_modules/optimize-css-assets-webpack-plugin/node_modules/postcss/lib/lazy-result.js:221:30)。然后 (/home/marcin/tmp/vuepress-testing/docs/node_modules/optimize-css-assets-webpack-plugin/node_modules/postcss/lib/lazy-result.js:206:17) 在 OptimizeCssAssetsWebpackPlugin.processCss (/home /marcin/tmp/vuepress-testing/docs/node_modules/optimize-css-assets-webpack-plugin/src/index.js:81:8)在对象。处理器 (/home/marcin/tmp/vuepress-testing/docs/node_modules/optimize-css-assets-webpack-plugin/src/index.js:20:18) 在 /home/marcin/tmp/vuepress-testing/docs /node_modules/last-call-webpack-plugin/src/index.js:150:10 at arrayEach (/home/marcin/tmp/vuepress-testing/docs/node_modules/lodash/_arrayEach.js:15:9) at forEach (/home/marcin/tmp/vuepress-testing/docs/node_modules/lodash/forEach.js:38:10) 在 OptimizeCssAssetsWebpackPlugin.process (/home/marcin/tmp/vuepress-testing/docs/node_modules/last-call- webpack-plugin/src/index.js:147:5) 在 /home/marcin/tmp/vuepress-testing/docs/node_modules/last-call-webpack-plugin/src/index.js:178:28 在 AsyncSeriesHook。 eval [as callAsync](创建时的评估(/home/marcin/tmp/vuepress-testing/docs/node_modules/tapable/lib/HookCodeFactory.js:33:10),:25:17)在 AsyncSeriesHook。lazyCompileHook (/home/marcin/tmp/vuepress-testing/docs/node_modules/tapable/lib/Hook.js:154:20) 在/home/marcin/tmp/vuepress-testing/docs/node_modules/webpack/lib/Compilation .js:1409:36 在 AsyncSeriesHook.eval [as callAsync] (创建时的 eval (/home/marcin/tmp/vuepress-testing/docs/node_modules/tapable/lib/HookCodeFactory.js:33:10),:9: 1) 在 AsyncSeriesHook.lazyCompileHook (/home/marcin/tmp/vuepress-testing/docs/node_modules/tapable/lib/Hook.js:154:20)154:20)154:20)

我还注意到,同样的错误开始出现在我现有的 VuePress 网站上,该网站之前没有问题(我认为甚至在昨天)。问题是什么?我能以某种方式绕过它吗?

Questioner
mnj
Viewed
0
AlekJnk 2021-06-23 18:06:17

同样在这里。我将 vuepress 锁定到 1.8.1 版本,并且构建似乎很好......直到错误修复。