pub fn to_vec<T: Sized>(value: &T) -> Result<Vec<u8>, Error> where T: Serialize,
Serialize the given data structure as a canonical JSON byte vector.