Configuration

Appearance

Theme mode, fonts, colors, code blocks, backgrounds, and page title breadcrumbs.

These docs.json keys control how your site looks. All of them are optional.

Appearance#

The appearance key sets the initial theme mode.

  • default: "system" (default), "light", or "dark". "system" follows the visitor's OS preference.
  • strict: hide the light/dark toggle and ignore stored preferences, locking the site to the default mode.

Colors#

  • primary: semantic primary color in light mode
  • light: semantic primary color in dark mode (defaults to primary)
  • dark: fallback accent used when primary is omitted

Fonts#

The fonts key replaces the default typefaces. Google Fonts families load automatically; self-hosted fonts need source (and optionally format).

The top-level family applies everywhere; heading and body override it for their part of the page.

Eyebrows#

The styling.eyebrows key controls the label above page titles: "section" (default) shows the group name, "breadcrumbs" shows the navigation path.

Code blocks#

The styling.codeBlocks key sets defaults for fenced code blocks. theme takes any bundled Shiki theme name per color mode, and lineNumbers turns on line numbers everywhere (individual blocks can opt out with hideLineNumbers).

Restart the dev server after changing the theme so already-compiled pages pick it up. See Code for the per-block syntax.

Background#

The background key sets a custom page background per mode. image can also be a single path used in both modes.

Last updated on
Edit this page