Hacker News new | ask | show | jobs
by amluto 4083 days ago
I don't normally like bashing open-source projects, but socket.io should not be used. It may be noob-friendly, but that's just because it does things so automatically that you can't really use it correctly. When I was a websockets noob, I used socket.io briefly, and it was a complete waste of time.

See, for example, https://github.com/Automattic/socket.io-client/issues/572 (closed without comment).

If you want a nice websockets library that handles old browsers, use SockJS. It's far better.

[edit: fixed a silly typo]

1 comments

Agreed - I've been using SockJS for a while and haven't had any issues. It's got a super-simple API. (intended to be as close to the WebSocket API as possible)

If your language of choice has a SockJS implementation, I'd recommend it as a first option.