diff options
author | Titus Wormer <tituswormer@gmail.com> | 2022-06-30 13:08:59 +0200 |
---|---|---|
committer | Titus Wormer <tituswormer@gmail.com> | 2022-06-30 13:08:59 +0200 |
commit | 13588776d65601a41ddfce85f618e8aaa55951cc (patch) | |
tree | e9f27d25a77c319eda50b6ae52a2ec5ba98824fd /examples/lib.rs | |
parent | bf9460fddeec7366df117ddae13b7d31d3354313 (diff) | |
download | markdown-rs-13588776d65601a41ddfce85f618e8aaa55951cc.tar.gz markdown-rs-13588776d65601a41ddfce85f618e8aaa55951cc.tar.bz2 markdown-rs-13588776d65601a41ddfce85f618e8aaa55951cc.zip |
Update todos
Diffstat (limited to '')
-rw-r--r-- | examples/lib.rs | 20 |
1 files changed, 2 insertions, 18 deletions
diff --git a/examples/lib.rs b/examples/lib.rs index 718e400..816aa33 100644 --- a/examples/lib.rs +++ b/examples/lib.rs @@ -1,24 +1,8 @@ extern crate micromark; -use micromark::{micromark, micromark_with_options, Options}; +use micromark::micromark; fn main() { - // Turn on debugging. - // You can show it with `RUST_LOG=debug cargo run --example lib` env_logger::init(); - // Safely turn (untrusted?) markdown into HTML. - println!("{:?}", micromark("# Hello, world!")); - - // Turn trusted markdown into HTML. - println!( - "{:?}", - micromark_with_options( - "<div style=\"color: tomato\">\n\n# Hello, tomato!\n\n</div>", - &Options { - allow_dangerous_html: true, - allow_dangerous_protocol: true, - default_line_ending: None - } - ) - ); + println!("{:?}", micromark("[](irc:///help)")); } |