Front matter
A Markdown file that opens with a --- line, flat key: value lines, and a closing --- shows those lines as a small list of facts above its body, in the browser and in the terminal (src/web/front_matter.ts is the one parser).
- A key is letters, digits,
_,.or-(up to 64), then:. A value is the rest of the line; matching quotes around it are dropped. A key with nothing after it is a fact with an empty value. - Flat only: no nesting, lists or multi-line values. At most 50 lines.
- Anything else (a line that is not
key: value, no closing---, an empty block,---not on the first line) is not front matter: the file shows as ordinary text. - Values are text. A link or an image in one is shown as written, never made live.
Try it: open a .md file starting with ---, title: Hello, ---.