jsonEncodedString not deal Date type
The jsonEncodedString not convert Date type,that make response by json with date type will fail. like this code will return fail to js client response.setHeader(.contentType, value: "application/json") let d: [String:Any] = ["a":1, "b":0.1, "c": true, "d":[2, 4, 5, 7, 8],"f":Date()] do{ try response.setBody(json: d) }catch{
}
response.completed()
Hope add Date type convert in jsonEncodedString
@kjessup Are you keeping jsonEncodedString in it's current form or are you going to implement Foundation's JSONEncoder everywhere?
It is recommended to use the String type
It's not an issue of whether converted to a String. The issue is a feature request to automatically handle the Date type.