找不到模块“socket.io" [英] Cannot find module "socket.io"
本文介绍了找不到模块“socket.io"的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在尝试运行 nodejs 脚本,它弹出以下错误消息:
Hi i am trying to run the nodejs script and it pops up the following error message:
我已经使用以下命令全局安装了 socket.io
:
I have installed socket.io
globally using following command:
>npm install -g socket.io
但仍然没有运气.
有什么帮助吗?
推荐答案
改为在本地使用,并保存到您的 package.json
Use it locally instead, and save to your package.json
npm install socket.io --save
这篇关于找不到模块“socket.io"的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文