This site provides a machine-readable index at /llms.txt.

Skip to main content Skip to navigation

Front matter key reference

The flat catalog of YAML keys parsed into the four shipped IFrontMatter records — DocFrontMatter, BlogFrontMatter, DocSiteFrontMatter, BlogSiteFrontMatter — via FrontMatterParser with CamelCaseNamingConvention. Keys are declared as init-only properties on records in Pennington.FrontMatter (core), Pennington.DocSite, and Pennington.BlogSite.

The base IFrontMatter interface every front-matter record implements supplies default member values (IsDraft = false, Search = true, Llms = true, Uid = null, Description = null, Date = null) so records only declare what they parse. See Pennington.FrontMatter.IFrontMatter for the interface surface.

Keys

Rows are alphabetical by YAML key. Each entry shows the records that expose the key, the declaring interface (IFrontMatter, one of the capability interfaces, or record-local for concrete-record properties), and every distinct type and default across records.

author string / string?
Default: "" / null

Applies to: BlogFrontMatter, BlogSiteFrontMatter. Declared on: record-local.

Author name shown in the byline and RSS feed.
date DateTime?
Default: null

Applies to: BlogFrontMatter, BlogSiteFrontMatter. Declared on: IFrontMatter.

Publication date. Posts are ordered by this date in archives and feeds.
description string?
Default: null

Applies to: BlogFrontMatter, BlogSiteFrontMatter, DocFrontMatter, DocSiteFrontMatter. Declared on: IFrontMatter.

Short post description used for meta tags, RSS summary, and archive listings.
isDraft bool
Default: false

Applies to: BlogFrontMatter, BlogSiteFrontMatter, DocFrontMatter, DocSiteFrontMatter. Declared on: IFrontMatter.

When true, the post is skipped during production builds.
llms bool
Default: true

Applies to: BlogFrontMatter, BlogSiteFrontMatter, DocFrontMatter, DocSiteFrontMatter. Declared on: IFrontMatter.

When false, the post is excluded from the generated llms.txt output.
order int
Default: int.MaxValue

Applies to: DocFrontMatter, DocSiteFrontMatter. Declared on: IOrderable.

Sort order within the containing section. Lower values appear first.
redirectUrl string?
Default: null

Applies to: BlogSiteFrontMatter, DocSiteFrontMatter. Declared on: IRedirectable.

When set, the post emits a client-side redirect to this URL instead of normal content.
repository string
Default: ""

Applies to: BlogSiteFrontMatter. Declared on: record-local.

URL to the post's source repository or related project (optional).
search bool
Default: true

Applies to: BlogFrontMatter, BlogSiteFrontMatter, DocFrontMatter, DocSiteFrontMatter. Declared on: IFrontMatter.

When false, the post is excluded from the search index.
sectionLabel string?
Default: null

Applies to: BlogSiteFrontMatter, DocFrontMatter, DocSiteFrontMatter. Declared on: ISectionable.

Section heading the post belongs under in navigation.
series string / string?
Default: "" / null

Applies to: BlogFrontMatter, BlogSiteFrontMatter. Declared on: record-local.

Series name grouping related posts together.
tags string[]
Default: []

Applies to: BlogFrontMatter, BlogSiteFrontMatter, DocFrontMatter, DocSiteFrontMatter. Declared on: ITaggable.

Tags applied to the post for filtering and the tag index.
title string
Default: "Empty title" / ""

Applies to: BlogFrontMatter, BlogSiteFrontMatter, DocFrontMatter, DocSiteFrontMatter. Declared on: IFrontMatter.

Post title.
uid string?
Default: null

Applies to: BlogFrontMatter, BlogSiteFrontMatter, DocFrontMatter, DocSiteFrontMatter. Declared on: IFrontMatter.

Stable identifier used for cross-references ([text](xref:uid)).

Notes

  • YAML keys are the camelCase form of the C# record property names — SectionLabel is written sectionLabel:, CanonicalBaseUrl is canonicalBaseUrl:. This is CamelCaseNamingConvention applied to YamlDotNet's default PascalCase binding; the FrontMatterKeys table above shows both the key and its backing symbol.
  • YAML keys are matched case-insensitively under CamelCaseNamingConvention (src/Pennington/FrontMatter/FrontMatterParser.cs); unknown keys are silently ignored (IgnoreUnmatchedProperties).
  • Absent keys fall through to the record's init default; IFrontMatter default members (IsDraft, Search, Llms, Uid, Description, Date) apply when the implementing record does not declare the property itself.
  • The concrete records DocFrontMatter, BlogFrontMatter, DocSiteFrontMatter, and BlogSiteFrontMatter all re-declare every default-member key explicitly, so their defaults are the ones listed above (not the interface defaults) when parsing is wired to a specific record type.

Example

---
title: Front matter
description: The YAML block at the top of every markdown page.
tags: [authoring, front-matter]
sectionLabel: authoring
order: 20
uid: kitchen-sink.main.front-matter
---
  
# Working with front matter
  
Every page in this site opens with a YAML block between `---` markers.
Those keys drive the sidebar title, description, tags, ordering, draft
state, and cross-reference `uid`. Each built-in front-matter record maps
the same keys onto a strongly-typed record.
  
## The built-in DocSite record
  
The DocSite template uses `DocSiteFrontMatter` under the hood. Its fields
cover the full capability surface — `Title`, `Description`, `IsDraft`,
`Tags`, `Order`, `RedirectUrl`, `Section`, `Uid`, `Search`, and `Llms`.
  
## A custom front-matter record
  
When you need extra fields, declare a record implementing `IFrontMatter`
(plus any capability interfaces you want). This site ships an
`ApiFrontMatter` record used by the API area to add `Namespace` and
`Stability` fields:
  
```yaml
---
title: Symbol reference
namespace: Pennington.Search
stability: preview
order: 30
---
```
  
Declare the record alongside your host project; Pennington discovers it
by type when you call `AddMarkdownContent<ApiFrontMatter>(...)`.

A DocSiteFrontMatter page populating title, description, tags, sectionLabel, order, and uid; the blog-only keys (author, series, repository, date) are demonstrated in examples/BlogSiteFirstPostExample/Content/Blog/my-first-post.md.

See also