Yeoman 未能 运行
Yeoman fails to run
我在 centos 7 上,我刚刚安装了 nodejs 版本 6.14.3、npm 版本 3.10.10 和 yo 版本 2.0.5。然后我 运行 命令
yo code
试图使用 yeoman 生成器创建 vscode 扩展。然后我收到以下错误:
/usr/lib/node_modules/generator-code/generators/app/index.js:47
async prompting() {
^^^^^^^^^
SyntaxError: Unexpected identifier
at createScript (vm.js:56:10)
at Object.runInThisContext (vm.js:97:10)
at Module._compile (module.js:549:28)
at Object.Module._extensions..js (module.js:586:10)
at Module.load (module.js:494:32)
at tryModuleLoad (module.js:453:12)
at Function.Module._load (module.js:445:3)
at Module.require (module.js:504:17)
at require (internal/module.js:20:19)
at Object.get [as code:app] (/usr/lib/node_modules/yo/node_modules/yeoman-environment/lib/store.js:39:27)
不确定我是否只是缺少一个愚蠢的依赖项或其他东西。有什么想法吗?
此节点版本 6.X 不支持 async
。
一定要安装更新的版本,我建议至少 8.X 不要冒语言级别的其他不兼容风险。
我在 centos 7 上,我刚刚安装了 nodejs 版本 6.14.3、npm 版本 3.10.10 和 yo 版本 2.0.5。然后我 运行 命令
yo code
试图使用 yeoman 生成器创建 vscode 扩展。然后我收到以下错误:
/usr/lib/node_modules/generator-code/generators/app/index.js:47
async prompting() {
^^^^^^^^^
SyntaxError: Unexpected identifier
at createScript (vm.js:56:10)
at Object.runInThisContext (vm.js:97:10)
at Module._compile (module.js:549:28)
at Object.Module._extensions..js (module.js:586:10)
at Module.load (module.js:494:32)
at tryModuleLoad (module.js:453:12)
at Function.Module._load (module.js:445:3)
at Module.require (module.js:504:17)
at require (internal/module.js:20:19)
at Object.get [as code:app] (/usr/lib/node_modules/yo/node_modules/yeoman-environment/lib/store.js:39:27)
不确定我是否只是缺少一个愚蠢的依赖项或其他东西。有什么想法吗?
此节点版本 6.X 不支持 async
。
一定要安装更新的版本,我建议至少 8.X 不要冒语言级别的其他不兼容风险。