Socket.IO 1.4.0 ship with new features like automatic compression for XHR and WebSockets, lots of bug fixes and significant performance and memory improvements.
Compression is enabled by default, as it’s highly beneficial for most application payloads. The following example shows the savings for a realtime stream of tweets.
Today we’re very happy to introduce Socket.IO P2P, the easiest way to establish a bidirectional events channel between two peers with a server fallback to provide maximum reliability.
Let’s look at the API and build a little chat application. Or check out the repository directly!
I’m really proud to announce the first release of the Socket.IO C++ Client on GitHub!
Based on Boost and WebSocket++, this full-featured Socket.IO 1.0 client has the fundamental advantage of working on multiple platforms. Check out the directory of examples. It contains examples of iOS, QT, and CLI chat clients!
To learn how to use this client, I put together a QT chat example that communicates using a Socket.IO Node.JS chat server. Keep reading for step-by-step instructions.
We are pleased to announce the immediate availability of the Socket.IO Swift Client! You’ll now be able to write code that runs natively on iOS and OSX, while maintaining the simplicity and expressiveness of the JavaScript client!
import Foundation
let socket = SocketIOClient(socketURL: "localhost:8880")
socket.on("important message") {data, ack in
println("Message for you! \(data?[0])")
ack?("I got your message, and I'll send my response")
socket.emit("response", "Hello!")
}
socket.connect()
To show how you can use it in a real project, I’ll show you how to create a small Tic Tac Toe app like the one shown above.