Skip to content

Commit

Permalink
Add tasklist_classes option to CLI
Browse files Browse the repository at this point in the history
  • Loading branch information
nicoburns committed Oct 13, 2024
1 parent f0d3a3b commit 975d3bf
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
1 change: 1 addition & 0 deletions fuzz/fuzz_targets/all_options.rs
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ fuzz_target!(|s: &str| {
render.ignore_empty_links = true;
render.gfm_quirks = true;
render.prefer_fenced = true;
render.tasklist_classes = true;

markdown_to_html(
s,
Expand Down
5 changes: 5 additions & 0 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,10 @@ struct Cli {
#[arg(long)]
relaxed_autolinks: bool,

/// Output classes on tasklist elements so that they can be styled with CSS
#[arg(long)]
tasklist_classes: bool,

/// Default value for fenced code block's info strings if none is given
#[arg(long, value_name = "INFO")]
default_info_string: Option<String>,
Expand Down Expand Up @@ -296,6 +300,7 @@ fn main() -> Result<(), Box<dyn Error>> {
.ignore_setext(cli.ignore_setext)
.ignore_empty_links(cli.ignore_empty_links)
.gfm_quirks(cli.gfm_quirks || cli.gfm)
.tasklist_classes(cli.tasklist_classes)
.build()?;

let options = Options {
Expand Down

0 comments on commit 975d3bf

Please sign in to comment.