Registry / serialization / serdeconv

serdeconv

JSON →
library0.4.1rscratesunverified

Provides convenient traits and functions for converting between TOML/JSON/MessagePack strings and serializable values.

# Cargo.toml [dependencies] serdeconv = "0.4.1"
INSTALL
IMPORT
SIG · SERDECONV
S
serdeconv
serializationrustv0.4.1
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

from_str
use serdeconv::from_str;

Deserializes a TOML string into a struct using serdeconv.

use serdeconv::from_str; use serde::Deserialize; #[derive(Deserialize)] struct Config { name: String, } fn main() { let toml = "name = \"example\""; let config: Config = from_str(toml).unwrap(); println!("Name: {}", config.name); }
Debug
Known issues
gotchaRequires the `serde` derive feature for custom types.
fix
Add `serde = { version = "1", features = ["derive"] }` to Cargo.toml.
affects: >=0.4.0
Upgrade
Version history
0.4.1latest on crates.io
Audit
Dependencies

No dependency data recorded yet.

Agent activity
9 hits · last 30 days
node
8
Resources
serdeconv — cargo add serdeconv · libregistry