HenniOKF
Documentation

Concept

The documentation in the application

How /docs arises from the bundle docs/, with table of contents, links and images.

What it is about

This documentation lies in the repository under docs/ and stands in the application under /docs, reachable through the menu item "Documentation". It is open to everyone, without signing in. It is itself an OKF bundle, the same kind of content the application will show from the next phase on.

What a page looks like

  • On the left the table of contents: start and log, then one part per area with the overview of the area and its pages, in the order of the index.md files. The current page is marked. The table can be collapsed; on a narrow screen it stands behind the button "Show contents".
  • On the right the way to the page, its type (Concept, Guide or Reference), its title, its description and the text.
  • The frame follows the language of the UI; the text of the pages is English.

How the pages arise

The list of addresses arises at build time from the files under docs/. An address is the path of the file without .md; an index.md stands for its directory:

FileAddress
docs/index.md/docs
docs/log.md/docs/log
docs/application/index.md/docs/application
docs/application/overview.md/docs/application/overview

An address that is not in the list is 404. The pages themselves are rendered at every request, so that the frame follows the cookie of the language. In the development server a change to docs/ takes effect at once, in the container only with a new image.

Links and images

  • A relative link to a file of the bundle leads to its page. Outside go only http, https and mailto. Every other link stays text.
  • Raw HTML in the Markdown is not executed; it stays text.
  • An image is shown only if it lies in the bundle and is linked relatively: PNG, JPEG or WebP with a name of lowercase letters, digits and hyphens. It comes through /docs-image/<path>, with width and height, so that the page does not jump while loading. A foreign image is never loaded.

How to write pages and what the test checks is under Writing documentation.

Next: Security.