Skip to content

2.0 is here!!

Compare
Choose a tag to compare
@s4cha s4cha released this 17 Apr 17:51
· 117 commits to master since this release

Nested values

value <-- json["nested.nested.nested.nestedValue"]

Object at index

value <-- json[12]

Combine both

value <-- json[1]?["someKey"]?[2]?["something.other"]

Looping on Array

if let collection = json.collection {
    for jsonEntry in collection {
        //Do something
    }
}

Custom Date format

createdAt <-- json["created_at"]?.dateFormat("yyyy-MM-dd'T'HH:mm:ssZZZZZ")