File tree 4 files changed +14
-2
lines changed
4 files changed +14
-2
lines changed Original file line number Diff line number Diff line change @@ -20,6 +20,7 @@ harness = false
20
20
[features ]
21
21
default = []
22
22
json = [" dep:serde" , " dep:serde_json" ]
23
+ log = [" dep:log" ]
23
24
24
25
[dependencies ]
25
26
log = { version = " 0.4" , optional = true }
Original file line number Diff line number Diff line change 1
1
fn main ( ) -> Result < ( ) , String > {
2
2
// Turn on debugging.
3
- // You can show it with `RUST_LOG=debug cargo run --example lib`
3
+ // You can show it with `RUST_LOG=debug cargo run --features log -- example lib`
4
4
env_logger:: init ( ) ;
5
5
6
6
// Safely turn (untrusted?) markdown into HTML.
Original file line number Diff line number Diff line change @@ -247,7 +247,7 @@ The following bash scripts are useful when working on this project:
247
247
```
248
248
* run examples:
249
249
` ` ` sh
250
- RUST_BACKTRACE=1 RUST_LOG=debug cargo run --example lib
250
+ RUST_BACKTRACE=1 RUST_LOG=debug cargo run --features log -- example lib
251
251
` ` `
252
252
* format:
253
253
` ` ` sh
Original file line number Diff line number Diff line change 11
11
//! constructs (GFM, MDX, and the like)
12
12
//! * [`to_mdast()`][]
13
13
//! — turn markdown into a syntax tree
14
+ //!
15
+ //! ## Features
16
+ //!
17
+ //! * **`default`**
18
+ //! — nothing is enabled by default
19
+ //! * **`json`**
20
+ //! — enable serde to serialize the AST (includes `dep:serde`, `dep:serde_json`)
21
+ //! * **`log`**
22
+ //! — enable logging (includes `dep:log`);
23
+ //! you can show logs with `RUST_LOG=debug`
24
+
14
25
#![ no_std]
15
26
#![ deny( clippy:: pedantic) ]
16
27
#![ allow( clippy:: doc_link_with_quotes) ]
You can’t perform that action at this time.
0 commit comments