-
Exported the internal function
find_pandoc()
, and also added two arguments,dir
andversion
, so that users can provide a custom directory under which this function may find Pandoc, as well as an expected version of Pandoc to be found (thanks, @connorp, #1785). -
pandoc_metadata_arg()
is a new Pandoc helper function to generate--metadata
argument for Pandoc command line (thanks, @cderv, #1789). -
The output format
html_vignette()
now warns against differences in the vignette title specified in thetitle
field in the YAML metadata and the one specified inside\VignetteIndexEntry{}
. Normally they are expected to be identical (#1789). -
Fixed a bug with encoding when rendering
html_notebook
containing HTML widgets (thanks, @cderv, #1799). -
TOC title can now be specified for
html_document
via the top-level optiontoc-title
in the YAML frontmatter (thanks, @atusy, #1771). -
Floating TOC can now distinguish upper/lower-cases (thanks, @atusy, #1783).
-
When
code_folding='show'
for the output formathtml_document
, code blocks can be individually hidden initially by specifying the chunk optionclass.source='fold-hide'
(thanks, @atusy, #1798). -
For LaTeX/PDF output formats
pdf_document
,beamer_presentation
, andcontext_document
, the argumentcitation_package = 'none'
was deprecated, andcitation_package = 'default'
should be used instead if citations are to be processed bypandoc-citeproc
(thanks, @njbart, rstudio/bookdown#754). -
output_format()
can now inheritkeep_md
andclean_supporting
frombase_format
whenNULL
is passed to these arguments. Previously, you must explicitly specifykeep_md
and/orclean_supporting
asTRUE
orFALSE
inoutput_format()
since they could not inherit the corresponding options ofbase_format
. This behavior was not consisent with other arguments ofoutput_format()
(thanks, @atusy, #1823). -
The
smart
argument of most output formats has been removed, because Pandoc'ssmart
extension is enabled by default, and settingsmart: false
for an output format did not really have any effect (which could be considered a bug, but we want to get rid of this option since it existed only for a historical reason for Pandoc 1.x, and Pandoc 2.x has been released for more than two years). If you want to disable thesmart
extension, you can use the optionmd_extensions: -smart
of the output format (thanks, @atusy, #1774). -
pdf_document()
should not specify thegeometry
variable when thedocumentclass
variable is passed to Pandoc (thanks, @jpcirrus, #1782). -
render()
now respects the YAML metadata in the R script when rendering the script with Pandoc 2.8 or later (thanks, @nsoranzo #1740, @cderv #1741). -
For
pandoc_convert()
, when the argumentto = 'pdf'
, it will be changed to'latex'
internally (thanks, @JohannesFriedrich, #1802). -
render(run_pandoc = FALSE)
no longer cleans up the Markdown file (typically knitted from Rmd) (thanks, @BrianDiggs, #1812).