3 releases (breaking)
0.3.0 | Aug 31, 2022 |
---|---|
0.2.0 | Aug 13, 2022 |
0.1.0 | Aug 13, 2022 |
#1238 in Encoding
25 downloads per month
Used in citeworks-cli
25KB
546 lines
Citation Style Language serde types and implementations.
This targets CSL 1.0.2 but may not support the entire specification.
At the moment, only CSL-JSON items are covered.
The top level API mimics [serde_json]'s:
let csl = citeworks_csl::from_str(r#"
[{
"id": "example-id",
"type": "report",
"author": [
{"given": "Jane", "family": "Roe"},
{"literal": "John Doe"}
]
}]
"#).unwrap();
assert_eq!(csl[0].author[0].given, Some("Jane".into()));
Dependencies
~0.8–1.6MB
~37K SLoC