laravel Echo does not listen to channel and events
I found the solution.
According to this comment on laravel-echo-server github page,The event name needs to be prefixed with a dot. like this :
echo.channel('user-channel.5').listen('.NewMessage', (e) => {
console.log(e);
});