无法生成node_modules文件;’live-server’ 不是内部或外部命令

来源:1-6 【拓展内容】nodejs&babel安装与配置(windows&mac&linux)-2

独木羊

2019-08-28

C:\Users\lenovo\WeChatProjects\minigame-1>node -v
v10.16.0

C:\Users\lenovo\WeChatProjects\minigame-1>npm -v
6.9.0

C:\Users\lenovo\WeChatProjects\minigame-1>npm install live-server
npm WARN deprecated opn@6.0.0: The package has been renamed to open
npm WARN lenovo No description
npm WARN lenovo No repository field.
npm WARN lenovo No license field.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {“os”:“darwin”,“arch”:“any”} (current: {“os”:“win32”,“arch”:“x64”})

  • live-server@1.2.1
    added 91 packages from 80 contributors and audited 9572 packages in 26.378s
    found 171 vulnerabilities (1 low, 170 high)
    run npm audit fix to fix them, or npm audit for details

C:\Users\lenovo\WeChatProjects\minigame-1>live-server
’live-server’ 不是内部或外部命令,也不是可运行的程序
或批处理文件。

写回答

1回答

傅猿猿

2019-08-28

安装少了个-g参数

0
3
独木羊
npm install也运行安装不起来 C:\Users\lenovo\WeChatProjects\minigame-1>npm install npm WARN lenovo No description npm WARN lenovo No repository field. npm WARN lenovo No license field. npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules\fsevents): npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"}) audited 9572 packages in 6.486s found 171 vulnerabilities (1 low, 170 high) run `npm audit fix` to fix them, or `npm audit` for details
2019-08-29
共3条回复

微信小游戏入门与实战,一天之内搞定微信小游戏开发

官方同步,第一时间掌握整套微信小游戏开发核心技术

3515 学习 · 664 问题

查看课程