first version with socket.io