
websocket
雨易辰木
简单就好
展开
-
vue-cli3项目运行时sockjs报错问题
vue-cli3项目运行时sockjs报错问题1.如图,项目中有websocket的内容,在控制台就会一直报错2.这是因为服务端没有启东时,就会一直出现3.解决方法在项目中找到node_modules下的sockjs-client/dist/sockjs.js在sockjs.js中找到代码的 1605行 注释掉,不让一直加载我用的是Hbulider直接ctrl+G直接到1605行try { // self.xhr.send(payload); } catch (e) {原创 2020-05-28 11:45:08 · 1669 阅读 · 0 评论 -
及时通讯之springboot集成websocket
springboot集成websocket导入maven依赖<!--websocket--> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-websocket</artifactId> </dependency>编写WebSocketConfig,启动时加载im原创 2020-05-20 16:00:32 · 221 阅读 · 0 评论