import Foundation extension JSONEncoder { static let devRant: JSONEncoder = { let encoder = JSONEncoder() encoder.dateEncodingStrategy = .iso8601 encoder.keyEncodingStrategy = .convertToSnakeCase return encoder }() } extension JSONDecoder { static let devRant: JSONDecoder = { let decoder = JSONDecoder() decoder.dateDecodingStrategy = .iso8601WithOptionalFractionalSeconds decoder.keyDecodingStrategy = .convertFromSnakeCase return decoder }() }