Skip to content

ndg: add frontmatter support for overriding implicit context#143

Merged
NotAShelf merged 8 commits intomainfrom
notashelf/push-vsowsonqrxnk
Mar 24, 2026
Merged

ndg: add frontmatter support for overriding implicit context#143
NotAShelf merged 8 commits intomainfrom
notashelf/push-vsowsonqrxnk

Conversation

@NotAShelf
Copy link
Copy Markdown
Member

@NotAShelf NotAShelf commented Mar 24, 2026

NDG now recognises a +++-delimited TOML block at the top of any .md file. For now, those are the supported keys:

  • title - overrides the (currently H1-derived) page title
  • description / author - override global meta.tags for that page
  • template - selects a specific Tera template instead of the default
  • toc - suppresses the table of contents when set to false
  • extra - arbitrary user data, accessible in templates as {{ page.extra.key }}. Meant as a way of injecting arbitrary variables into the templating system from the sources.

All fields are also exposed to Tera templates via page context objects.

Signed-off-by: NotAShelf <raf@notashelf.dev>
Change-Id: I1449f465f5cc625efcfbbba6f50387f16a6a6964
Signed-off-by: NotAShelf <raf@notashelf.dev>
Change-Id: Iac3da7393986c838d6326cdfcdfbd3636a6a6964
Signed-off-by: NotAShelf <raf@notashelf.dev>
Change-Id: Id0e632c85f55e20a5e811ac33d312b606a6a6964
Signed-off-by: NotAShelf <raf@notashelf.dev>
Change-Id: I47b37bc982cf28b1c4b2cdda75648c7e6a6a6964
Signed-off-by: NotAShelf <raf@notashelf.dev>
Change-Id: I22d93480e28b490d4cdf0778046e5fec6a6a6964
Signed-off-by: NotAShelf <raf@notashelf.dev>
Change-Id: Iaa27b7b0d9c134e90d9cf1db2f4258d66a6a6964
@NotAShelf NotAShelf marked this pull request as ready for review March 24, 2026 19:18
…tml`

Signed-off-by: NotAShelf <raf@notashelf.dev>
Change-Id: Ib616e1a8e7d2653e28b59468c5b006e96a6a6964
Signed-off-by: NotAShelf <raf@notashelf.dev>
Change-Id: I1d6d31120f8d559b510a9f573a4552826a6a6964
@NotAShelf
Copy link
Copy Markdown
Member Author

builds for me I ain't waiting for this stupid GH CI

@NotAShelf NotAShelf merged commit e9bf604 into main Mar 24, 2026
10 checks passed
@NotAShelf NotAShelf deleted the notashelf/push-vsowsonqrxnk branch March 24, 2026 19:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant