socket.io version code example
Example 1: install socket.io
npm i socket.io
Example 2: socket.io documentation
const socket = new WebSocket('ws://localhost:3000');socket.onopen(() => { socket.send('Hello!');});socket.onmessage(data => { console.log(data);});