@@ -7,7 +7,7 @@ Socket.IO-client for iOS/OS X.
7
7
``` swift
8
8
import SocketIO
9
9
10
- let socket = SocketIOClient (socketURL : URL (string : " http://localhost:8080" )! , config : [.log (true ), .forcePolling ( true ) ])
10
+ let socket = SocketIOClient (socketURL : URL (string : " http://localhost:8080" )! , config : [.log (true ), .compress ])
11
11
12
12
socket.on (clientEvent : .connect ) {data, ack in
13
13
print (" socket connected" )
@@ -30,7 +30,7 @@ socket.connect()
30
30
``` objective-c
31
31
@import SocketIO;
32
32
NSURL * url = [[NSURL alloc ] initWithString: @"http://localhost:8080" ] ;
33
- SocketIOClient* socket = [[ SocketIOClient alloc] initWithSocketURL: url config:@{@"log": @YES , @"forcePolling ": @YES }] ;
33
+ SocketIOClient* socket = [[ SocketIOClient alloc] initWithSocketURL: url config:@{@"log": @YES , @"compress ": @YES }] ;
34
34
35
35
[ socket on:@"connect" callback:^(NSArray* data, SocketAckEmitter* ack) {
36
36
NSLog(@"socket connected");
@@ -92,7 +92,7 @@ Then import `import SocketIO`.
92
92
### Carthage
93
93
Add this line to your ` Cartfile ` :
94
94
```
95
- github "socketio/socket.io-client-swift" ~> 10.0.1 # Or latest version
95
+ github "socketio/socket.io-client-swift" ~> 10.1.0 # Or latest version
96
96
```
97
97
98
98
Run ` carthage update --platform ios,macosx ` .
@@ -104,7 +104,7 @@ Create `Podfile` and add `pod 'Socket.IO-Client-Swift'`:
104
104
use_frameworks!
105
105
106
106
target ' YourApp' do
107
- pod ' Socket.IO-Client-Swift' , ' ~> 10.0.1 ' # Or latest version
107
+ pod ' Socket.IO-Client-Swift' , ' ~> 10.1.0 ' # Or latest version
108
108
end
109
109
```
110
110
@@ -132,7 +132,7 @@ Objective-C:
132
132
Add this line to your ` Seedfile ` :
133
133
134
134
```
135
- github "socketio/socket.io-client-swift", "v10.0.1 ", :files => "Source/*.swift" # Or latest version
135
+ github "socketio/socket.io-client-swift", "v10.1.0 ", :files => "Source/*.swift" # Or latest version
136
136
```
137
137
138
138
Run ` seed install ` .
0 commit comments