Open umarcor opened 4 years ago
Those keys are Pandoc variables define in YAML metablock (https://pandoc.org/MANUAL.html#extension-yaml_metadata_block) - they are not used by rmarkdown output format directly in R and only processed by Pandoc.
This is the way you need to specified those variables.
We maybe offer new ways to provide some keys but this would be a rmarkdown change and it would still use Pandoc feature (default file or metadata file perhaps)
However, I understand the idea of specific format option not at top level. This would more work to support as rmarkdown would need to know which are Pandoc variables, and pass them to Pandoc directly, whereas now Pandoc is reading the variable from the YAML header directly.
Thanks for the suggestion and having open the discussion. We'll not consider it in the near feature but this may attract some 👍 in the future, and it will be interesting to consider if we rething how to pass variable to Pandoc template.
When trying to use options such as
documentclass
,lof
,biblio-title
,margin-left
ormargin-right
in the preamble of the index/rootRmd
file, I found that only adding them at the top-level would work:Instead, I would have expected those keys to be supported in
output > bookdown::pdf_book:
:However, if I use the latter format, those options seem to be silently ignored.
Find full example repo: LarsAsplund/github-facts.