8 releases (1 stable)

1.0.0 Jan 4, 2025
0.3.0 Jan 4, 2025
0.1.5 Aug 26, 2024

#1032 in Parser implementations

Download history 8/week @ 2024-09-18 11/week @ 2024-09-25 6/week @ 2024-10-02 2/week @ 2024-10-09 1/week @ 2024-11-13 2/week @ 2024-12-04 2/week @ 2024-12-11 242/week @ 2025-01-01

246 downloads per month
Used in http-srv

MIT license

32KB
871 lines

Json parser for rust


lib.rs:

Json parser

Example

use json::Json;

let j = Json::deserialize(r#"{
    "array" : [ 1, 2, "3", null ],
    "true" : true,
    "nested" : {
        "inner" : []
    }
}"#).unwrap();

let Json::Object(map) = j else { panic!() };
assert!(
    matches!(
        map.get("true"),
        Some(Json::True)));

No runtime deps

~0–0.9MB