diff options
Diffstat (limited to '')
-rw-r--r-- | examples/lib.rs | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/examples/lib.rs b/examples/lib.rs index b1869bb..94c2c58 100644 --- a/examples/lib.rs +++ b/examples/lib.rs @@ -1,5 +1,5 @@ extern crate micromark; -use micromark::{micromark, micromark_with_options, Options}; +use micromark::{micromark, micromark_with_options, Constructs, Options}; fn main() { // Turn on debugging. @@ -21,4 +21,19 @@ fn main() { } ) ); + + // Support extensions that are not in CommonMark. + println!( + "{:?}", + micromark_with_options( + "---\ntitle: Neptune\n---\nSome stuff on the moons of Neptune.", + &Options { + constructs: Constructs { + frontmatter: true, + ..Constructs::default() + }, + ..Options::default() + } + ) + ); } |