title | teaching | exercises |
---|---|---|
Using Markdown |
10 |
2 |
:::::::::::::::::::::::::::::::::::::: questions
- How do you write a lesson using Markdown and
{sandpaper}
?
::::::::::::::::::::::::::::::::::::::::::::::::
::::::::::::::::::::::::::::::::::::: objectives
- Explain how to use markdown with The Carpentries Workbench
- Demonstrate how to include pieces of code, figures, and nested challenge blocks
::::::::::::::::::::::::::::::::::::::::::::::::
This is a lesson created via The Carpentries Workbench. It is written in Pandoc-flavored Markdown for static files and R Markdown for dynamic files that can render code into output. Please refer to the Introduction to The Carpentries Workbench for full documentation.
What you need to know is that there are three sections required for a valid Carpentries lesson:
questions
are displayed at the beginning of the episode to prime the learner for the content.objectives
are the learning objectives for an episode displayed with the questions.keypoints
are displayed at the end of the episode to reinforce the objectives.
:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: instructor
Inline instructor notes can help inform instructors of timing challenges associated with the lessons. They appear in the "Instructor View"
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
::::::::::::::::::::::::::::::::::::: challenge
What is the output of this command?
paste("This", "new", "lesson", "looks", "good")
:::::::::::::::::::::::: solution
[1] "This new lesson looks good"
:::::::::::::::::::::::::::::::::
:::::::::::::::::::::::: solution
You can add a line with at least three colons and a solution
tag.
::::::::::::::::::::::::::::::::: ::::::::::::::::::::::::::::::::::::::::::::::::
You can use standard markdown for static figures with the following syntax:
![optional caption that appears below the figure](figure url){alt='alt text for accessibility purposes'}
{alt='Blue Carpentries hex person logo with no text.'}
One of our episodes contains
$\alpha = \dfrac{1}{(1 - \beta)^2}$
becomes:
Cool, right?
::::::::::::::::::::::::::::::::::::: keypoints
- Use
.md
files for episodes when you want static content - Use
.Rmd
files for episodes when you need to generate output - Run
sandpaper::check_lesson()
to identify any issues with your lesson - Run
sandpaper::build_lesson()
to preview your lesson locally
::::::::::::::::::::::::::::::::::::::::::::::::