What does it mean for a page to be a chapter?

In the tutorial the instruction says to create a chapter-type article, but I can’t find anywhere what it means for an article to be a chapter. How does an article being a chapter affect rendering? Does it change the order, visual appearance, anything else?

Ah sorry that’s specific to the “learn” template, I’ll go ask there.

I think that “chapter-type article” means directories that contain markdown files like _index.md

For example, /content/shortcodes/_index.en.md will be rendered to Shortcodes :: Documentation for Hugo Learn Theme


It’s not just that - I’m indeed using the learn template, but that uses “chapter = true” in some of the pages and it’s seemingly not strictly tied to the file being _index.md (otherwise why have the chapter = true if you can already infer that from the filename?)

I think my problem mainly stems from not understanding what structure the learn template expects - I’m migrating a jekyll site and most of my pages currently don’t show up.

Chapter is not in the DOCs, can be a special part of your choosen theme

I found that, it’s something from the learn template.

I checked the source code of the learn theme. If you set chapter = true at _index.en.md, the content will be rendered like the following.

chapter = true creates <div id="chapter">...</div>

title: Basics
weight: 5
pre: "<b>1. </b>"
chapter: true

### Chapter 1

# Basics

Discover what this Hugo theme is all about and the core-concepts behind it.