未找到模块:错误:无法解析“node_modules/stompjs/lib"中的“net" [英] Module not found: Error: Can't resolve 'net' in 'node_modules/stompjs/lib'

查看:33
本文介绍了未找到模块:错误:无法解析“node_modules/stompjs/lib"中的“net"的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

遇到了一个找不到 stompJS-lib 的问题,我收到以下错误消息:

Got an issue where a stompJS-lib was not found, upon which I got the following error message:

Module not found: Error: Can't resolve 'net' in '/../../../.../../../angular-app/node_modules/stompjs/lib'

推荐答案

以下命令(安装缺少的依赖项):

The following command (which installs the missing dependencies):

 npm i net -S

这不会像下面假设的那样安装随机包.如果您希望前端在这些所需依赖项的客户端上进行某种级别的非权威处理,那么这是可以考虑的选项.

This does not install random packages as assumed below. If you want the frontend to have some level of non-authoritative processing to be done on the client-side of those required dependencies, then this is the option to consider.

这篇关于未找到模块:错误:无法解析“node_modules/stompjs/lib"中的“net"的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆