papyrus

Back

Collections

What Papyrus collections are and how folder-backed collection routes work.

A collection is a folder of posts with a TOML file that describes the public collection page. It is useful when readers need to follow posts in a deliberate order instead of the normal date-based blog order.

The same Markdown post can appear in the regular /posts/ archive and in a collection route. The archive sorts by publishing metadata; the collection sorts by filename so authors can control the sequence.

Folder shape

Create a folder under src/content/posts and add a TOML file inside it:

src/content/posts/
  docs/
    docs.toml
    start/
      00-papyrus-docs.md
      03-site-config.md
    references/
      25-collections.md
txt

Papyrus detects TOML files below src/content/posts. The collection slug comes from the folder name, so src/content/posts/docs/docs.toml becomes /collections/docs/.

Collection config

src/content/posts/docs/docs.toml
name = "Papyrus docs"
description = "Package docs for installing, composing, and extending Papyrus."

[settings]
post_footer = "collection"
post_footer_collapsible = true

[[sections]]
name = "Start"
description = "Getting started and configuration."

[[sections]]
name = "References"
description = "Reusable route and content references."
toml

Sections are matched by folder slug. A section named Start reads posts from start/; a section named References reads posts from references/.

Ordering

Collection pages use filename order, not post date order. Prefix filenames when the order matters:

start/00-papyrus-docs.md
start/01-features.md
start/02-install-configure-papyrus.md
start/03-site-config.md
txt

Keep explicit slug frontmatter when moving a post into a collection. That preserves the normal /posts/my-slug/ route while also adding the collection route at /collections/docs/my-slug/.

Post pages inside a collection

Collection post pages receive collection-aware navigation:

  • the back link points to the collection page
  • previous and next links follow filename order
  • the table of contents can include collection sections
  • the footer can show the current collection, collapsed by default

Use collection routes when context and sequence matter. Use normal post routes when date order and discovery are the main concern.

Hiding collection posts

hidden: true keeps a post reachable by direct URL but removes it from public collection lists, feeds, tag pages, sitemap, search, and AI indexes. Use it for fixtures and private-ish drafts that should not be part of public discovery.

Part of Papyrus docs.