schemars
schemars copied to clipboard
Add implementations for the time crate
This adds a new feature, time, which enables the time crate. JsonSchema implementations are provided for the time::{OffsetDateTime, PrimitiveDateTime, Date, Time}. The existing time modules are renamed to std_time.
@GREsau Can you please accept this PR? Thanks.
I'd also love to use this feature, I prefer time over chrono. If it helps increase the priority, there's another PR to add this feature: https://github.com/GREsau/schemars/pull/207
I'd also like this added. In my current API, I copied this implementation of JsonSchema for PrimitiveDateTime into a helper function so I could use it.
I've rebased this against current master if that helps. However, it looks like there's an issue with MSRV with one of time's dependencies.