Currently date_time is a subtype of strings.. This is for historical reasons because we used to only support generating JSON, which does not know date times as anything else other than strings.
Nowadays, we generate into databases as well, which have first-class support for more primitive types (incl. date times) than JSON does. So we made internally the date_time nodes generate chrono::DateTime and format separately. But date_time is still a subtype of string, which is not the best UX.
Currently
date_time
is a subtype of strings.. This is for historical reasons because we used to only support generating JSON, which does not know date times as anything else other than strings.Nowadays, we generate into databases as well, which have first-class support for more primitive types (incl. date times) than JSON does. So we made internally the
date_time
nodes generatechrono::DateTime
and format separately. Butdate_time
is still a subtype ofstring
, which is not the best UX.This is to simply move the
content::string::DateTime
node to be acontent::Content
variant of its own right, with its value of type like"type": "date_time"
.