Invalid JSON while parsing \n (quoted) string
问题 I have a problem with a Codable parsing... that's my example code: class Test: Codable { let resultCount: Int? let quote: String? } var json = """ { "resultCount" : 42, "quote" : "My real quote" } """.data(using: .utf8)! var decoder = JSONDecoder() let testDecoded = try! decoder.decode(Test.self, from: json) Here everything works as expected and the Test object is created. Now my back end sends me the quote string with a quote in the middle... in this form (please note \"real\" ): class Test: