connection event in the client socket io code example
Example: how to send an event to one socket in socket.io
// sends the event to the socket that has the specified id.
io.to(socketId).emit("event", data);
// sends the event to the socket that has the specified id.
io.to(socketId).emit("event", data);