News for hackers. Stuff that matters.
Re:Introducing Socket.io 1.0 by xhrpost on Wednesday May 28, 2014 @02:52PM (#7812071)
I've used Socket.IO quite a bit, congrats on shipping! Did the issue/"lack of feature" get fixed where not all transport methods fire a disconnect event? That was especially a pain on a recent project, ended up forcing websocket only to get around it. EDIT: Ack, I should probably clarify this better. The issue is that a client disconnected is not determined by the server. The server waits for the client to send a disconnect event to it prior to leaving the page. This is particularly a problem on iPad where the event will not fire for certain transports so disconnect doesn't fire when you shut off an iPad unless websockets are actively used.
Re:Introducing Socket.io 1.0 by antonapa on Wednesday May 28, 2014 @06:27PM (#7813365)
I solved this by firing an event on window.beforeunload. Had the same issue.