it is part of database but graphql doesn't have an...
# orm-help
r
it is part of database but graphql doesn't have an implicit scalar for datetime, so you need to extend the scalar types and then come up with a custom argument type
🇨🇿 1
2
m
I know that's the case, but imho nexus is about developer experience. So I would argue the field which is used in every table should come out of the box. just my opinion...
r
Yeah I'd share that opinion, but i think the issue is that once you make a decision on how to serialize the Date object, then you'd need to follow that standard on the client too in order to deserialize correctly. So now client is thrown into the mix and even more opinions arise from that.
I.e. do you serialize it into a timestamp integer or iso string format?
m
iso string format
but still... one recommended version should come out of the box
kind of an opinionated best practices approach.
👍 1
r
maybe we'll get better ergonomics in the next GraphQL version, there's some reading about scalars here https://github.com/graphql/graphql-spec/issues/635
👀 1