question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Listening to 'connection' event with io.on not working

See original GitHub issue

Tried to work through the first example in “How to use” using version 0.8.7, and found that it worked if I called io.of('').on but not io.on. It looks like the ‘connection’ event was emitted from SocketNamespace, but io.on was adding the listener to Manager.

Issue Analytics

  • State:closed
  • Created 12 years ago
  • Comments:12 (1 by maintainers)

github_iconTop GitHub Comments

0reactions
debasish-khancommented, Jan 12, 2021

Could anyone help with this ?

Read more comments on GitHub >

github_iconTop Results From Across the Web

node.js - Socket.io server not listening to connection event
I started my server and its work well But even after the client page loads and is served, connection event is not listened...
Read more >
Troubleshooting connection issues | Socket.IO
First and foremost, please note that disconnections are common and expected, even on a stable Internet connection:
Read more >
Socket.IO, React and Node.js: Going Real-Time
We can listen for a connection event, fire up a function when a new user connects to the server, emit a message (basically...
Read more >
Introduction to Sockets.IO in Node.js - GeeksforGeeks
Restart the project again from the console and try opening the localhost on multiple tabs and browsers. Each of them will act as...
Read more >
Socket.IO - Event Handling - Tutorialspoint
log('A user connected'); // Send a message after a timeout of 4seconds setTimeout(function(){ socket.send('Sent a message 4seconds after connection!'); }, ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found