angular7使用mqtt,build后出现‘ws//localhost:8083’,而不是使用指定的IP地址去连接mqtt

问题:mqtt自己把自己设为了localhost

解决:

1. 找到 node_modules/ngx-mqtt/src/mqtt.service.js

2. 搜索hostname,找到‘localhost’,将其改为自己的IP地址

 

angular7使用mqtt,build后出现‘ws//localhost:8083’的问题

 

相关文章:

  • 2021-12-26
  • 2021-04-06
  • 2021-10-06
  • 2021-08-28
  • 2021-05-01
  • 2022-12-23
  • 2021-07-09
  • 2022-12-23
猜你喜欢
  • 2022-02-19
  • 2022-12-23
  • 2021-07-16
  • 2021-10-01
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案