This gives me the “Type ‘Business’ does not conform to protocol ‘Decodable’. …” error. Removing CodingKeys enum fixes that. I"m just following Les 7 Mod 6
struct Business : Decodable, Identifiable {
var id: String?
var name: String?
var alias: String?
var isClosed: Bool?
var imageUrl: String?
var reviewCount : Int?
var categories : [Category]?
var rating : Double?
var coordinates : Coordinate?
var transactions: [String]?
var price: String?
var displayPhone: String?
var distance: Double?
var location : Location?
enum CodingKeys : String, CodingKey {
case imageUrl = "image_url"
case isClosed = "is_closed"
case reviewCount = "review_count"
case displayPhone = "display_phone"
case id
case name
case alias
case url
case categories
case transactions
case price
case location
case distance
case coordinates
}
}