Right now API requests return json but only (sometimes) define a type for the return body. There should be some system in place where the client can know exactly what the return type will be.
The main issue I ran into here was that I am returning dates in /api/calendar_events. Without proper type casting these dates remain strings and cause issues later on where the client expects them to be date objects.
Right now API requests return json but only (sometimes) define a type for the return body. There should be some system in place where the client can know exactly what the return type will be.
The main issue I ran into here was that I am returning dates in
/api/calendar_events
. Without proper type casting these dates remain strings and cause issues later on where the client expects them to be date objects.Or maybe we should be returning dates as int...