Description Usage Arguments Details Value Examples
Reasonably savvy in selecting the right option for your output.
1 | render_chunk(x, options, inline = FALSE, ...)
|
x |
Character. Chunk output. |
options |
List. Options as passed from |
inline |
Logical. As passed from |
... |
Other parameters passed from |
Currently the function uses render_html_chunk
if the knitr
output is an htmlwidget
or knitr_kable
.
Otherwise, if results
is set to "asis",
it uses render_asis_chunk
.
For standard fenced output (beginning and ending with three backticks),
surprisinglytidy
relies on sassy.js
to post-process Pandoc-syntax classes into remark.js classes.
knitr
object for printing.
1 2 3 4 5 6 7 8 9 10 11 12 | ## Not run:
# In \code{knitr} setup:
knitr::opts_chunk$set( # first option tells knitr to use function
render = surprisinglytidy::render_chunk
class.source = ".r-source", # you can set each separately
class.warning = ".r-warning",# class.output is what render_chunk will use
class.message = ".r-message",# note that you can use multiple classes,
class.error = ".r-error", # separated by a space
class.output = ".r-output .another-class"
)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.