Registry / utility / json-comments

json-comments

JSON →
library0.2.2rscratesunverified

Library to strip comments from JSON before parsing

# Cargo.toml [dependencies] json_comments = "0.2.2"
INSTALL
IMPORT
SIG · JSON-COMMENTS
J
json-comments
utilityrustv0.2.2
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.

strip_comments
use json_comments::strip_comments;

Strips comments from a JSON string.

use json_comments::strip_comments; let json_with_comments = r#"{ // comment "key": "value" }"#; let clean = strip_comments(json_with_comments).unwrap(); println!("{}", clean);
Debug
Known issues

No known issues recorded.

Upgrade
Version history
0.2.2latest on crates.io
Audit
Dependencies

No dependency data recorded yet.

Agent activity
6 hits · last 30 days
node
6
Resources
json-comments — cargo add json-comments · libregistry