Answer the question
In order to leave comments, you need to log in
Not connecting to sockets?
Customer:
import { io } from "socket.io-client";
io('ws://127.0.0.1:5000/')
const app = express()
const server = require('http').createServer(app)
const socketIO = require('socket.io')
const io = new socketIO.Server(server)
io.on("connection", (socket) => {
console.log(socket.id);
})
GET http://127.0.0.1:5000/socket.io/?EIO=4&transport=polling&t=NlJrC6b net::ERR_CONNECTION_REFUSED
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question