📜  获取客户端 ID 套接字 io - Javascript 代码示例

📅  最后修改于: 2022-03-11 15:01:28.846000             🧑  作者: Mango

代码示例1
// NodeJs 
// Socket.io get id client connected
io.on('connection', (socket) => {
    console.log(socket.id) // This is ID session the client
});