score:1

Accepted answer
useEffect(() => {
    webSocket.on('messageRecieved', (message) => {
       console.log(listValue.current);
    }); 
}, []);

score:0

.catch((error) => {
    console.log(error.response)
})

Related Query

More Query from same tag