Serialize and Deserialize
Derive macros.
What is Serde?
Serde (SERialize/DEserialize) is Rust's framework for converting data structures to and from formats like JSON, YAML, and more.
- Format-agnostic core plus format crates
- Driven by derive macros
Adding serde
Add serde with the derive feature, plus a format crate like serde_json. This edits Cargo.toml.
[dependencies]
serde = { version = "1", features = ["derive"] }
serde_json = "1"All lessons in this course
- Serialize and Deserialize
- Working with JSON
- Custom Serialization
- Other Formats