AndroMasta AndroMasta - 3 months ago 26
Swift Question

Swift 3 json parsing library suggestion

I'd like to parse some JSON data with swift but its very difficult for me to do because of optionals. How to do this?

I tried using Standard libraries to do this


Try to use SwiftyJSON library

With SwiftyJSON all you have to do is:

let json = JSON(data: dataFromNetworking) if let userName = json[0]["user"]["name"].string { //Now you got your value }