Error: Cannot find module 'commander'

编程入门 行业动态 更新时间:2024-10-23 12:31:49

Error: Cannot <a href=https://www.elefans.com/category/jswz/34/1771123.html style=find module 'commander'"/>

Error: Cannot find module 'commander'

1、错误描述

C:\Users\Administrator.USER-0GUONPPBHK>vue list
internal/modules/cjs/loader.js:596throw err;^Error: Cannot find module 'commander'at Function.Module._resolveFilename (internal/modules/cjs/loader.js:594:15)at Function.Module._load (internal/modules/cjs/loader.js:520:25)at Module.require (internal/modules/cjs/loader.js:650:17)at require (internal/modules/cjs/helpers.js:20:18)at Object.<anonymous> (D:\nodejs\node_modules\vue-cli\bin\vue:3:17)at Module._compile (internal/modules/cjs/loader.js:702:30)at Object.Module._extensions..js (internal/modules/cjs/loader.js:713:10)at Module.load (internal/modules/cjs/loader.js:612:32)at tryModuleLoad (internal/modules/cjs/loader.js:551:12)at Function.Module._load (internal/modules/cjs/loader.js:543:3)C:\Users\Administrator.USER-0GUONPPBHK>

2、错误原因

     使用vue list查看所有的可用的官方模板,出现找不到模块commander

3、解决办法

(1)直接执行安装commander模块命令

cnpm install commander --save

(2)全局安装vue-cli

npm i vue-cli -g

更多推荐

Error: Cannot find module 'commander'

本文发布于:2024-02-14 12:47:49,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1763252.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:find   Error   commander   module

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!