vue-cli3 一直运行 /sockjs-node/info?t= 解决方案

问题描述:

  项目运行时一直发送http://localhost:8080/sockjs-node/info?t=1462183700002请求

 

问题原因:

  首先sockjs-node是一个JavaScript库,提供跨浏览器JavaScript的API,创建了一个低延迟,全双工的浏览器和web服务器之间通信通道。
  服务端:sockjs-node(https://github.com/sockjs/sockjs-node)
  客户端:sockjs-clien(https://github.com/sockjs/sockjs-client)
  如果你的项目没有用到sockjs,vuecli3 运行npm run serve 之后network里面一直调用一个接口:
        http://localhost:8080/sockjs-node/info?t=1556418283950

 解决方法:

  从根源上关闭此调用
  1、node_modules/sockjs-client/dist/sockjs.js 
  2、代码的1605行注释
    // self.xhr.send(payload);
  ps:可在代码开发完成后关闭,会同步关闭热加载
 
 

转载于:https://www.cnblogs.com/liAnran/p/11214019.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
These dependencies were not found: * @/api/second/category/industry in ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/views/trivoltine/std_base/editStructure.vue?vue&type=script&lang=js& * @/api/second/structure/crud in ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/views/trivoltine/std_base/seeStructure.vue?vue&type=script&lang=js& * @/components/tinymce-editor/tinymce-editor.vue in ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/views/trivoltine/std_base/editStructure.vue?vue&type=script&lang=js& * vue-pdf in ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/views/trivoltine/std_base/editStructure.vue?vue&type=script&lang=js& * vue-quill-editor in ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/views/trivoltine/std_base/editStructure.vue?vue&type=script&lang=js& To install them, you can run: npm install --save @/api/second/category/industry @/api/second/structure/crud @/components/tinymce-editor/tinymce-editor.vue vue-pdf vue-quill-editor
05-23

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值