I'm sending via SignalR a DateTime Object from ServerSide without unspecified kind:
myDate.Kind //Unspecified
I'm setting the JsonConvert defaultSettings to use UTC, as suggested here:
JsonConvert.DefaultSettings = () => new JsonSerializerSettings(){
DateTimeZoneHandling = DateTimeZoneHandling.Utc
};
If I use the JsonConvert.SerializeObject I obtain the string in UTC ISO8601 format, with "Z" suffix:
JsonConvert.SerializeObject(myDate) // "\"2014-11-27T23:00:00Z\""
But, If I send the object via SignalR, at client side I Receive:
myDate: "2014-11-27T23:00:00"
Notice it returns without Z suffix.
Is SignalR not using JsonConvert? Why I'm getting two different results?
My goal is to receive client side: "2014-11-27T23:00:00Z"