Description Usage Arguments Images and figures YAML config Badges
First looks for index.Rmd
or README.Rmd
, then
index.md
or README.md
. If none are found, falls back to the
description field in DESCRIPTION
.
1 | build_home(pkg = ".", override = list(), preview = NA, quiet = TRUE)
|
pkg |
Path to package. |
override |
An optional named list used to temporarily override
values in |
preview |
If |
quiet |
Set to |
If you want to images in your README.md
, they must be stored in
somewhere in the package so that they can be displayed on the CRAN
website. The best place to put them appears to be man/figures
.
If you are generating figures with R Markdown, make sure you set up
fig.path
as followed:
1 2 3 4 5 | ```{r, include = FALSE}
knitr::opts_chunk$set(
fig.path = "man/figures/"
)
```
|
To tweak the home page, you need a section called home
.
The sidebar links are automatically generated by inspecting the
URL
and BugReports
fields of the DESCRIPTION
.
You can add additional links with a subsection called links
,
which should contain a list of text
+ href
elements:
1 2 3 4 |
The "developers" list is populated by the maintainer ("cre"), authors ("aut"), and funder ("fnd").
You can remove the first heading with
1 2 | home:
strip_header: true
|
Status badges are displayed in the sidebar under the section "Dev status". This section is automatically populated if the first paragraph of the homepage consists solely of status badges as linked images.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.