Stat Mania
  • Course Template
  • All Courses
  1. Writing Lessons
  2. Anatomy of a lesson
  • Course Home
  • Start Here
    • How the template works
    • Project structure
  • Writing Lessons
    • Anatomy of a lesson
    • Components
    • Code blocks and live code
  • Make It Yours
    • Theming
    • Rendering and publishing

On this page

  • The front matter
  • A good lesson shape
  • Check your understanding
  1. Writing Lessons
  2. Anatomy of a lesson

Anatomy of a lesson

The front matter fields that drive the lesson header and the home page.
Reading 7 min

By the end of this lesson you will

  • Write a lesson’s front matter
  • Choose a lesson kind and time estimate
  • Write learning objectives that show up in the header

Cheat sheet

minutes: 7
Time chip; turns the header on
kind: code
read, code, quiz or lab
objectives:
List shown in the header box
cheatsheet:
Right-rail quick reference
rail-links:
Right-rail links

Resources

  • Quarto front matter options

Look at the top of this page: the coloured chips (Reading, 7 min) and the box with objectives. None of that is written in the page body. It is all drawn from the front matter.

The front matter

---
title: "Anatomy of a lesson"
description: "One sentence. Shown on the home page and in search."
minutes: 7
kind: read          # read | code | quiz | lab
objectives:
  - "Write a lesson's front matter"
  - "Choose a lesson kind and time estimate"
---
Field Used for
title Page title, sidebar entry, home page row
description Subtitle and the grey line under the row on the home page
minutes The time chip, the module total and the course total
kind The icon and colour: read, code, quiz or lab
objectives The “By the end of this lesson you will” box
Importantminutes switches the header on

The header is only drawn on pages that define minutes. Module overview pages omit it on purpose.

A good lesson shape

  1. Objectives (from front matter).
  2. A short opening that says why this matters.
  3. One idea per ## heading. Each heading becomes an entry in the right-hand outline.
  4. A Check your understanding section with one to three questions.
  5. A .takeaways block with two to four bullets.

Discuss first

If you could only keep three bullets of this lesson, which would they be? Hold that thought: it is exactly what goes in the takeaways box.

Check your understanding

Q1. Which front matter field turns the lesson header on?

  • Front matter drives the header, time estimates and the home page.
  • kind is one of read, code, quiz or lab.
  • Keep one idea per heading and end with a quiz and takeaways.
Back to top
Stat Mania

Free, hands-on statistics and programming courses that run right in your browser.

Courses

All courses R Programming Statistics Probability

Resources

Practice quizzes Tools & games Quarto docs Course kit on GitHub

Company

Home About Contact Privacy policy Terms of use
© Stat Mania. All rights reserved.
Writing Lessons
Components