How to implement the resumption konecsni socket.io?

In online games such as agar.if io breaks the Internet soedineniya and resume it within a short period of time, the client continues from the same place where you left off. On the server I use socket.io.
io.on("connection",function (socket) {
console.log("Player "+socket.id+" connected");
});
The problem is that when reconnecting, the server creates another connection with a new socket id. The question is how do you know that joined the and passed out a few seconds ago? Thought to store on the client id of the first conexin, which transfer to the server. This is the normal approach? Maybe you can resume the session automatically?
July 2nd 19 at 14:24
1 answer
July 2nd 19 at 14:26
Solution
Can you help is the solution Stack Overflow
Thanks, I like this and want to implement it, just thought it is possible somehow to resume connection with the same socket id - nikita.Stracke commented on July 2nd 19 at 14:29

Find more questions by tags Node.jsSocket.io