You can customise the homepage sidebar with the home.sidebar
field.
It's made up of two pieces: structure
, which defines the overall layout, and components
, which defines what each piece looks like.
This organisation makes it easy to mix and match the pkgdown defaults with your own customisations.
This is the default structure:
home: sidebar: structure: [links, license, community, citation, authors, dev]
These are drawn from seven built-in components:
links
: automated links generated from URL
and BugReports
fields from DESCRIPTION
plus manual links from the home.links
field:
yaml
home:
links:
- text: Link text
href: https://website.com
- text: Roadmap
href: /roadmap.html
license
: Licensing information if LICENSE
/LICENCE
or LICENSE.md
/LICENCE.md
files are present.
community
: links to to .github/CONTRIBUTING.md
, .github/CODE_OF_CONDUCT.md
, etc.
citation
: link to package citation information. Uses either inst/CITATION
or, if absent, information from the DESCRIPTION
.
authors
: selected authors from the DESCRIPTION
.
dev
: development status badges extracted from README.md
/index.md
. This is only shown for "development" versions of websites; see "Development mode" in ?build_site
for details.
toc
: a table of contents for the README (not shown by default).
You can also add your own components, where text
is markdown text:
home: sidebar: structure: [authors, custom, toc, dev] components: custom: title: Funding text: We are *grateful* for funding!
Alternatively, you can provide a ready-made sidebar HTML:
home: sidebar: html: path-to-sidebar.html
Or completely remove it:
home: sidebar: FALSE
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.