WebSocket connection failed: Error during WebSocket handshake: Unexpected response code: 400

后端 未结 16 1466
攒了一身酷
攒了一身酷 2020-12-04 21:08

I am trying to integrate Socket.io with Angular and I\'m having difficulties making a connection from the client-side to the server. I\'ve looked through other related quest

16条回答
  •  心在旅途
    2020-12-04 21:53

    In your controller, you are using an http scheme, but I think you should be using a ws scheme, as you are using websockets. Try to use ws://localhost:3000 in your connect function.

提交回复
热议问题