Calling encode with a datetime properly casts to a Google.Timestamp
Protobuf.encode(%MyProto{created_at: DateTime.utc_now()})
But calling the JSON module to encode results in an error
Protobuf.JSON.encode(%MyProto{created_at: DateTime.utc_now()})
# function DateTime.__message_props__/0 is undefined or private
It seems that Protobuf.JSON.Encode.encodable doesn't have a clause to handle DateTimes. Is there a reason for this? Would a PR be accepted to handle DateTimes?
Calling encode with a datetime properly casts to a Google.Timestamp
But calling the JSON module to encode results in an error
It seems that
Protobuf.JSON.Encode.encodabledoesn't have a clause to handle DateTimes. Is there a reason for this? Would a PR be accepted to handle DateTimes?