I’ve EJSONified a custom data type that contains a Date property. If I hand this object over in a method call, it is transfered from the client to the server with the correct (custom) data type. However, the date property is initialized as a string containing the ISO formatted date information, it is not a Date object. Why is this so? The docs state that EJSON has full support for Date types.
what kind of date format u expect?
and they also state you can set EJSON.addType(name, factory) where factory is function to transform to your type
so you can check customType.toJSONValue() output and set that factory function to revert it