binary-extract 0.3.0

Extract a value from a json string without parsing the whole thing
Documentation

binary-extract

Extract a value from a json string without parsing the whole thing.

📖 Docs

📦 Crate

Installation

$ cargo add binary-extract

Example

let value = binary_extract::extract(r#"{"foo": "bar"}"#, "foo").unwrap();
assert_eq!(value, "bar");

Perf

With the object from benches/json.rs, extract() is ~3.5x faster than json::parse.

See also

License

MIT