pub fn to_vec<T: Serialize + ?Sized>(data: &T) -> Result<Vec<u8>, Error>Expand description
Encode Serialize data exactly as JSON.stringify would encode its numbers.
ยงErrors
Returns an error if the input cannot be serialized as JavaScript-compatible JSON.