Websocket can be written natively, but will an error be reported with socket.io-client?

proxy configured, local port is 9527

proxy: {
  "/socketServer": {
    target: "ws://192.168.30.76:8087",
    changeOrigin: true,
    ws: true,
  },
},
let ws = new WebSocket("ws://localhost:9527/socketServer/server-admin")
ws.onopen = function(data) {
  console.log("WebSocket: ")
}    

Native writing this is a successful
clipboard.png

Socket.io-client~


clipboard.png

I don"t know what"s wrong.

Mar.18,2022

does the backend also need to use socket.io 's library?


socket.io is a little different from WebSocket. If you want to use socket.io backend, you also need socket.io

.
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b2baed-2affe.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b2baed-2affe.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?