make_aio_section | R Documentation |
When an episode needs to be added to the AiO, this will insert the XML nodes from the episode contents in its own section inside the All In One page.
make_aio_section(name, contents, parent)
name |
the name of the section, prefixed with |
contents |
the episode contents from |
parent |
the parent div of the AiO page. |
the section that was added to the parent
build_aio()
, get_content()
if (FALSE) {
lsn <- "/path/to/lesson"
pkg <- pkgdown::as_pkgdown(fs::path(lsn, "site"))
# read in the All in One page and extract its content
aio <- get_content("aio", content = "self::*", pkg = pkg)
episode_content <- get_content("01-introduction", pkg = pkg)
make_aio_section("aio-01-introduction",
contents = episode_content, parent = aio
)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.