Configuration

Configure your documentation with a docs.json file.

Add a docs.json file to the root of your GitHub repository to configure your documentation. Below is a list of all available configuration options, which can be used to modify the logos, theme, analytics and more.

If your IDE supports JSON Schemas, you can add a $schema property to your docs.json file to enable autocompletion and validation:

docs.json
{
  "$schema": "https://docs.page/schema.json"
}

Properties

Top-level properties

namestring

The name of your project. This will be displayed in the header of your documentation and used for other aspects such as automatic social preview images.

descriptionstring

A short description of your project. This will be used in meta tags and social preview images.

faviconstring | Favicon

Defines the favicon to show in the browser tab.

See Asset URLs for more information on how to add assets to your documentation.

The favicon can either be a string value which will be used for both light and dark modes, or a Favicon object to define separate favicons for light and dark modes.

socialPreviewstring

An asset URL to use as the default social preview image for your documentation.

If not provided, a social preview image will be automatically generated. Individual pages can override this social preview URL by specifying a socialPreview property in their frontmatter.

See Asset URLs for more information on how to add assets to your documentation.

Logo

logoLogo

Configures the logo of your documentation, which will be displayed in the header and used for social preview images.

The minimum height of the logo should be 24px. Note that if only a light or dark logo is provided, it will be used for both light and dark modes.

See Asset URLs for more information on how to add assets to your documentation.

Theme

themeTheme

Configures the theme of your documentation. If not provided, a default theme will be used.

Header

headerHeader

Configures the header of your documentation.

Anchors

anchorsAnchor[]

Configures the anchor links of your documentation.

Social Links

socialobject

An object of key value pairs where the key is the social platform and the value is the username/ID to link to:

{
  "social": {
    "x": "@invertaseio",
    "github": "invertase"
  }
}

SEO

seoSEO

Configures the SEO settings of your documentation.

Variables

variablesobject

An object of common variables which can be replaced in your documentation content using the {{ variableName }} syntax. For example, the following:

{
  "variables": {
    "versions": {
      "default": "1.0.0",
    }
  }
}

Can be replaced via the {{ versions.default }} syntax in your documentation content.

Search

searchSearch

Configures the search settings of your documentation.

Scripts

scriptsScripts

Configures the scripts to include in your documentation.

Content

contentContent

Configures how the content of your documentation is displayed.

Tabs

tabsTab[]

An array of Tab objects to display at the top of your documentation. See Navigation for more information on how to configure tabs.

Sidebar

sidebarSidebar[] | Record<string, Sidebar>

An array or object of Sidebar objects to display in the sidebar of your documentation. See Navigation for more information on how to configure the sidebar.