1 unstable release
Uses old Rust 2015
0.1.0 | Aug 22, 2018 |
---|
#20 in #flatten
6KB
117 lines
Usage example
extern crate flatten_json;
use flatten_json::flatten_from_str;
fn main() {
let json = r#"
{
"user": {
"name": "tom",
"id": 115026,
},
"role": "AUTHOR",
"status": "APPROVED"
}
#";
let flat_json = flatten_from_str(json).unwrap();
println!("{}", flat_json);
// {"user.name":"tom","user.id":115026,"role":"AUTHOR","status":"APPROVED"}
}
Dependencies
~0.5–1MB
~20K SLoC