html_page: An R Markdown output format for 'blogdown' web pages

Description Usage Arguments Details Note References

View source: R/format.R

Description

This function is a simple wrapper of bookdown::html_document2() with different default arguments, and more importantly, a special HTML template designed only for blogdown to render R Markdown to HTML pages that can be processed by Hugo.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
html_page(
  ...,
  number_sections = FALSE,
  self_contained = FALSE,
  highlight = NULL,
  template = NULL,
  pandoc_args = NULL,
  keep_md = FALSE,
  pre_knit = NULL,
  post_processor = NULL
)

Arguments

..., number_sections, self_contained, highlight, template, pandoc_args

Arguments passed to bookdown::html_document2() (note the option theme is not supported and set to NULL internally, and when template = NULL, a default template in blogdown will be used).

keep_md, pre_knit, post_processor

Passed to rmarkdown::output_format.

Details

The HTML output is not a complete HTML document, and only meaningful to blogdown (it will be post-processed to render valid HTML pages). The only purpose of this output format is for users to change options in YAML.

The fact that it is based on bookdown means most bookdown features are supported, such as numbering and cross-referencing figures/tables.

Note

Do not use a custom template unless you understand how the default template actually works (see the blogdown book).

The argument highlight does not support the value "textmate", and the argument template does not support the value "default".

References

See Chapter 2 of the bookdown book for the Markdown syntax: https://bookdown.org/yihui/bookdown. See the blogdown book for full details: https://bookdown.org/yihui/blogdown.


blogdown documentation built on Sept. 5, 2021, 5:42 p.m.

Related to html_page in blogdown...