vue serve命令問題
vue ui等等執(zhí)行都是正常,vue-cli是全局安裝的
但是執(zhí)行vue serve的時候提示
?Command vue serve requires a global addon to be installed.
? Please run npm install -g @vue/cli-service-global and try again.
vue ui等等執(zhí)行都是正常,vue-cli是全局安裝的
但是執(zhí)行vue serve的時候提示
?Command vue serve requires a global addon to be installed.
? Please run npm install -g @vue/cli-service-global and try again.
2019-01-16
舉報
2019-01-16
你的報錯的這兩句話直譯過來就是 “vue serve命令需要全局安裝,請使用npm install -g @vue/cli-service-global”
如果以上的命令執(zhí)行后還是不行,請檢查 :
檢查npm, node版本。
給node命令執(zhí)行的cmd終端“超級管理員權(quán)限”。
重新安裝cli命令工具:npm install -g @vue/cli , 使用vue serve命令還需要安裝:npm install -g @vue/cli-service-global
檢查 cli版本。
重新運行vue serve
2019-01-16
在root權(quán)限下也可以查看vue版本
2019-01-16
執(zhí)行npm安裝語句會報錯
npm WARN deprecated circular-json@0.3.3: CircularJSON is in maintenance only, flatted is its successor.
npm ERR! Unexpected end of JSON input while parsing near '...endencies":{"@webasse'
npm ERR! A complete log of this run can be found in:
npm ERR! ? ? /var/root/.npm/_logs/2019-01-16T07_55_56_672Z-debug.log