Hi, I wrote two new (optional) features in my own fork of ulid-rs, and I'd like to know if you'd welcome pull requests for either of them. They are:
serde: this pulls in serde and implements Serialize and Deserialize for Ulid. The 26-char representation is used by default, and I also wrote a module that can serialize as the inner primitive u128 by annotating structs with #[serde(with = "ulid_as_u128")];
uuid: this is a tiny convenience feature that pulls in the uuid crate and implements the conversions From<Uuid> for Ulid and From<Ulid> for Uuid, both infallible. These come in handy when interacting with systems that expect UUIDs.
Hi, I wrote two new (optional) features in my own fork of
ulid-rs
, and I'd like to know if you'd welcome pull requests for either of them. They are:serde
and implementsSerialize
andDeserialize
forUlid
. The 26-char representation is used by default, and I also wrote a module that can serialize as the inner primitiveu128
by annotating structs with#[serde(with = "ulid_as_u128")]
;uuid
crate and implements the conversionsFrom<Uuid> for Ulid
andFrom<Ulid> for Uuid
, both infallible. These come in handy when interacting with systems that expect UUIDs.