/

Document types

The .doctype function defines the type of document based on different use cases. Each document type offers its own set of features and behaviors tailored to specific output formats.

Plain (plain)

A plain document has a linear layout with no page breaks, allowing content to flow continuously from top to bottom. Thanks to its responsive design, this type works well for websites and knowledge management documents, resembling the style of tools such as Notion or Obsidian.

The document consists of three main elements:

Plain

Margin content

Page margin content appears in a fixed position that remains visible as you scroll.

Footnotes

Footnotes appear as sidenotes in this document type, positioned in the right margin area next to their first reference. On mobile devices, footnotes appear at the end of the page instead.

PDF

When you export to PDF, the output artifact contains a single page that fits the entire content.

Paged (paged)

A paged document follows a traditional layout with content divided into separate pages. Page breaks occur either explicitly through manual insertion or implicitly when content exceeds the available space.

Paged

Margin content

Page margin content appears on each page in a dedicated area.

Footnotes

Footnotes appear at the bottom of the page where their first reference occurs, in a dedicated area.

Slides (slides)

A slides document is designed for presentations, with a layout optimized for displaying content one slide at a time. Unless specified by the layout theme, slides center their content horizontally. Slide breaks occur only through explicit insertion.

Slides

Margin content

Page margin content appears on each slide without a dedicated area, which means it could potentially overlap the actual content.

Footnotes

Footnotes appear at the bottom of the slide where their first reference occurs, without a dedicated area.

PDF

When you export to PDF:

Docs (docs)

A docs document is designed for technical documentation, featuring a structured navigation-first layout with sidebars, a header with a search bar, and navigation buttons in the footer. This type is ideal for creating wikis, guides, and reference materials. The wiki you are currently reading is a docs document!

Docs documents leverage subdocuments, and include a lightweight, precise and client-side search functionality that allows finding content within the entire documentation set.

Margin content

Footnotes

Footnotes appear at the bottom of the page, in a dedicated area.