xml_to_md | R Documentation |
Convert xml to markdown
xml_to_md(body, stylesheet = "xml2md_gfm_kramdown.xsl", newlines = FALSE)
body |
an xml document |
stylesheet |
the name of a stylesheet passed to |
newlines |
a logical indicating that newlines (aka softbreaks) should
be inserted between elements (defaults to |
a character vector of length 1
cha <- pegboard:::make_div("challenge")
sol <- pegboard:::make_div("solution")
xml2::xml_add_child(cha, xml2::xml_child(sol, 1), .where = 1)
xml2::xml_add_child(cha, xml2::xml_child(sol, 2), .where = 2)
cat(pegboard:::xml_to_md(cha))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.