ocadotechnology / codeforlife-ios

2 stars 0 forks source link

Pull out all the string constants in AnimationFactory #41

Open mutantbutton2 opened 8 years ago

mutantbutton2 commented 8 years ago

Something is probably wrong with the SwiftyJson:

In SwiftyJson 2.2.1,

private struct JsonIdentifier {
  static let Type = "type"
}

let IdentifierType = "type"
let type = json["type"].string // compile ok
let type = json[IdentifierType].string // compile ok
let type = json[JsonIdentifier.Type].string // compile error