distill
distill copied to clipboard
Support for Submenus
In rmarkdown (at least v2.10+), there is support for submenus (https://github.com/rstudio/rmarkdown/pull/1426) in rmarkdown website. This doesn't seem to work in distill (v1.2) websites. For instance, consider the following _site.yml
:
name: "site"
navbar:
title: "My Website"
left:
- text: "Home"
href: index.html
- text: "About"
href: about.html
menu:
- text: "Sub_1"
href: sub1.html
- text: "Sub_2"
menu:
- text: "Sub_2_below"
href: sub2.html
And the following index.Rmd
:
---
params:
root_dir: NULL
title: "Distill Website"
description: |
Scientific and technical writing, native to the web
output:
distill::distill_article:
toc: true
code_folding: true
---
# Home Page
When we render this Rscript --slave -e "rmarkdown::render('index.Rmd')"
, the index.html has this menu:
The "SUB_2" has no submenu. While if you change the index.Rmd
to:
---
params:
root_dir: NULL
title: "Distill Website"
description: |
Scientific and technical writing, native to the web
---
# Home Page
such that the output is no longer a distill article, but a rather rmarkdown article then we get this:
.
Is it possible to get support for submenus in distill websites?