I'm building a NestJS API and I would like to expose to the API my Date objects as unix timestamps / custom string formats.
By default, NestJS use the format shown in this example: "2020-02-24T07:01:31.229Z"
Any idea of how to easily configure this without having to make my API objects hold a "number" or "string" (aka, manually converting it) instead of a Date?
Note that I'm not asking about TypeORM and how to store date objects. This is a question about how to make the NestJS serialize/deserialize Date objects into JSON.
Thanks,
ClassTransformer(or theValidationPipewithtransform: true)?