>,
) -> fmt::Result {
if attributes.contains_key("lang") {
write!(output, "", attributes["lang"])
} else {
output.write_str("")
}
}
fn write_code_tag(
&self,
output: &mut dyn Write,
attributes: HashMap<&'static str, Cow>,
) -> fmt::Result {
if attributes.contains_key("class") {
write!(output, "", attributes["class"])
} else {
output.write_str("")
}
}
}
fn main() {
let adapter = PotatoSyntaxAdapter::new(42);
let options = Options::default();
let mut plugins = options::Plugins::default();
plugins.render.codefence_syntax_highlighter = Some(&adapter);
let input = concat!("```Rust\n", "fn main<'a>();\n", "```");
let formatted = markdown_to_html_with_plugins(input, &options, &plugins);
println!("{}", formatted);
}