let manager = SocketManager(socketURL: URL(string: "Some url")!, config: [.log(true), .compress])
var socket:SocketIOClient!
var name: String?
var resetAck: SocketAckEmitter?
override func viewDidLoad() {
super.viewDidLoad()
socket = manager.defaultSocket
socket.on(clientEvent: .connect) {data, ack in
print("socket connected")
}
self.socket.on(clientEvent: .error) {data, ack in
print("error")
}
self.socket?.on(clientEvent: .disconnect){data, ack in
print("disconnect")
}
socket.connect()
}
ERROR SocketEnginePolling: Error during long poll request
LOG SocketIOClient{/}: Handling event: error with data: ["Error"]