View source: R/validate_lesson.R
validate_lesson | R Documentation |
A validator based on the pegboard::Lesson class cached with this_lesson()
that will provide line reports for fenced divs, links, images, and heading
structure. For details on the type of validators avaliable, see the
{pegboard}
article Validation of Lesson Elements
validate_lesson(path = ".", headings = FALSE, quiet = FALSE)
path |
the path to the lesson. Defaults ot the current directory |
headings |
If |
quiet |
if |
We expect the headings to be semantic and informative. Details of the tests
for headings can be found at pegboard::validate_headings()
Internal links and images should exist and images should have alt text.
Details for these tests can be found at pegboard::validate_links()
Callout Blocks should be one of the expected types. Details for this test
can be found at pegboard::validate_divs()
a list with the results for each test as described in pegboard::Lesson
tmp <- tempfile()
lsn <- create_lesson(tmp, open = FALSE)
validate_lesson(lsn, headings = TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.