{"action":"created","issue":{"url":"https://api.github.com/repos/triniwiz/nativescript-socketio/issues/26","repository_url":"https://api.github.com/repos/triniwiz/nativescript-socketio","labels_url":"https://api.github.com/repos/triniwiz/nativescript-socketio/issues/26/labels{/name}","comments_url":"https://api.github.com/repos/triniwiz/nativescript-socketio/issues/26/comments","events_url":"https://api.github.com/repos/triniwiz/nativescript-socketio/issues/26/events","html_url":"https://github.com/triniwiz/nativescript-socketio/issues/26","id":182001652,"number":26,"title":"How to use in NativeScript + angular 2","user":{"login":"mubbashar","id":378379,"avatar_url":"https://avatars.githubusercontent.com/u/378379?v=3","gravatar_id":"","url":"https://api.github.com/users/mubbashar","html_url":"https://github.com/mubbashar","followers_url":"https://api.github.com/users/mubbashar/followers","following_url":"https://api.github.com/users/mubbashar/following{/other_user}","gists_url":"https://api.github.com/users/mubbashar/gists{/gist_id}","starred_url":"https://api.github.com/users/mubbashar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mubbashar/subscriptions","organizations_url":"https://api.github.com/users/mubbashar/orgs","repos_url":"https://api.github.com/users/mubbashar/repos","events_url":"https://api.github.com/users/mubbashar/events{/privacy}","received_events_url":"https://api.github.com/users/mubbashar/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":37,"created_at":"2016-10-10T12:23:37Z","updated_at":"2016-10-24T20:26:41Z","closed_at":null,"body":"Is there any tutorial for integration in NativeScript + angular 2 . I am not able to make it work\r\nPlease guide to some tutorial\r\n\r\nthanks!"},"comment":{"url":"https://api.github.com/repos/triniwiz/nativescript-socketio/issues/comments/255855764","html_url":"https://github.com/triniwiz/nativescript-socketio/issues/26#issuecomment-255855764","issue_url":"https://api.github.com/repos/triniwiz/nativescript-socketio/issues/26","id":255855764,"user":{"login":"tviel","id":1053681,"avatar_url":"https://avatars.githubusercontent.com/u/1053681?v=3","gravatar_id":"","url":"https://api.github.com/users/tviel","html_url":"https://github.com/tviel","followers_url":"https://api.github.com/users/tviel/followers","following_url":"https://api.github.com/users/tviel/following{/other_user}","gists_url":"https://api.github.com/users/tviel/gists{/gist_id}","starred_url":"https://api.github.com/users/tviel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tviel/subscriptions","organizations_url":"https://api.github.com/users/tviel/orgs","repos_url":"https://api.github.com/users/tviel/repos","events_url":"https://api.github.com/users/tviel/events{/privacy}","received_events_url":"https://api.github.com/users/tviel/received_events","type":"User","site_admin":false},"created_at":"2016-10-24T20:26:41Z","updated_at":"2016-10-24T20:26:41Z","body":"A new project, simply created by \r\n`tns create`\r\nthen \r\n`tns plugin nativescript-socketio`\r\n`tns prepare ios`\r\n\r\nchanging the podfile to include \r\n\r\n```\r\npost_install do |installer|\r\n  installer.pods_project.targets.each do |target|\r\n    target.build_configurations.each do |config|\r\n      config.build_settings['SWIFT_VERSION'] = '3.0'\r\n    end\r\n  end \r\nend\r\n```\r\n\r\nand doing a `pod install` in platforms ios\r\ncompiles successfull when\r\n`tns run ios --emulator`\r\n\r\nafter adding\r\n\r\n`\r\nvar socket = new SocketIO('<your-url>',{});\r\n        socket.connect()\r\n        socket.emit('info',{});\r\n`\r\n\r\ncrashes with same error.\r\n\r\nI included the sample project for convenience\r\n[socket-test.zip](https://github.com/triniwiz/nativescript-socketio/files/548906/socket-test.zip)\r\n\r\n\r\nAs said, checking the code of the used SocketIOSwiftClient (8.0.x), it tells to \r\n\r\n```swift\r\nimport SocketIO\r\nlet socket = SocketIOClient(socketURL: URL(string: \"http://localhost:8080\")!, config: [.log(true), .forcePolling(true)])\r\n\r\nsocket.on(\"connect\") {data, ack in\r\n    print(\"socket connected\")\r\n}\r\n\r\nsocket.on(\"currentAmount\") {data, ack in\r\n    if let cur = data[0] as? Double {\r\n        socket.emitWithAck(\"canUpdate\", cur)(0) {data in\r\n            socket.emit(\"update\", [\"amount\": cur + 2.50])\r\n        }\r\n\r\n        ack.with(\"Got your currentAmount\", \"dude\")\r\n    }\r\n}\r\n\r\nsocket.connect()\r\n```\r\n\r\nwhich is emit and emitWithAck, not emitWithItems nor emitWithAckWithItems\r\n\r\nWhat else can I do to support?"}}
{"actor":{"display_login":"tviel"}}