-
Support a
rename_all
specification that applies only to the Serialize impl or only to the Deserialize impl (#1447, thanks @vincascm)#[derive(Serialize, Deserialize)] #[serde(rename_all( serialize = "camelCase", deserialize = "SCREAMING_SNAKE_CASE", ))] struct S { /* ... */ }
-
Allow serializing struct name inside of structs with named fields (#1448, thanks @motu42)
#[derive(Serialize)] #[serde(tag = "type")] struct S { /* ... */ } // serializes as {"type":"S",...}