update readme

This commit is contained in:
Erik 2016-08-14 23:05:02 -04:00
parent e567067d44
commit 5e1dc53304
No known key found for this signature in database
GPG Key ID: 4930B7C5FBC1A69D

View File

@ -5,6 +5,8 @@ Socket.IO-client for iOS/OS X.
##Example
```swift
import SocketIO
let socket = SocketIOClient(socketURL: NSURL(string: "http://localhost:8080")!, config: [.Log(true), .ForcePolling(true)])
socket.on("connect") {data, ack in
@ -26,6 +28,7 @@ socket.connect()
##Objective-C Example
```objective-c
@import SocketIO;
NSURL* url = [[NSURL alloc] initWithString:@"http://localhost:8080"];
SocketIOClient* socket = [[SocketIOClient alloc] initWithSocketURL:url config:@{@"log": @YES, @"forcePolling": @YES}];
@ -115,13 +118,13 @@ Import the module:
Swift:
```swift
import SocketIOClientSwift
import SocketIO
```
Objective-C:
```Objective-C
@import SocketIOClientSwift;
@import SocketIO;
```
CocoaSeeds