You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'd like to use this crate's serde_value::Value as a more generic version of serde_json::Value.
My use case is an HTTP API where the success response body is defined as such:
#[derive(serde::Serialize)]structSuccessBody{data: serde_json::Value,}implSuccessBody{pubfnnew(data:implInto<serde_json::Value>) -> Self{let data = data.into();Self{ data }}}
Since most (all?) serialize_* are infallible, e.g:
I'd like to use this crate's
serde_value::Value
as a more generic version ofserde_json::Value
.My use case is an HTTP API where the success response body is defined as such:
Since most (all?)
serialize_*
are infallible, e.g:serde-value/src/ser.rs
Lines 77 to 87 in 47190f5
this should be trivial to implement.
I can submit a PR if you believe this is worth implementing.
The text was updated successfully, but these errors were encountered: