The page
This page gives the shape of a page of docs. It has the first sentence, the order of the sections, and the four kinds of pages with a template for each.
The first sentence
The first sentence says what the reader gets from the page. A reader decides in that sentence if the page is the right one. Flight Manual makes the first paragraph the meta description, so search engines show it too.
These first sentences come from the docs of ztcl and ztk:
- "This page builds a small window with a script and a stylesheet." (ztk, Quick start)
- "This guide shows drops of files and text on a widget, drags from a widget to other apps, and drags between widgets of one app." (ztk, Drag and drop)
- "ztcl runs scripts that you did not write." (ztcl, Limits)
The four kinds of pages
Give each page one kind. A page that mixes kinds makes a reader with a task read the theory, and a reader who wants a fact read the steps.
| Kind | The reader wants | The page has | Template |
|---|---|---|---|
| Start | A first result, fast | Steps in order, each with a command and its output | start.md |
| Guide | To do one task | The steps of the task, the check of the result, and the repair of each fault | guide.md |
| Reference | One exact fact | Each command, option, key, or error, in one form, complete | reference.md |
| Explanation | To understand | How a part works and why, with no instructions | explanation.md |
The docs of Flight Manual have the four kinds as the four groups of the menu.
The order of the sections
- A start page and a guide follow the order of the work: what you need, the steps, the check, and the repair.
- A reference page follows one form on each page of the set, so a reader finds the same part at the same place. Each command page of ztk has the sections Synopsis, Arguments, Return value, Errors, Example, Platforms, and See also, in that order.
- An explanation goes from the whole to the parts.
- Each page ends with a link to the next page.
Lists, tables, and pictures
- Put a sequence of steps in a numbered list, and a set of items in a list with bullets.
- Put a comparison in a table. The options of a command, the errors and their repairs, and the pairs of the voice are tables.
- Keep a paragraph to six sentences or fewer.
- Use a picture when the reader must see a result: a page, a window, a layout. Give it a text that says what it shows. Make it with a tool of the repository (see Reference and examples).
Code and output
Show each command with its output, in a code block with a language. Use console for a command and its output with a $ prompt, sh for commands only, and text for output alone.
$ flight-manual version
flight-manual 0.1.0
Limits
Say what does not work, and what was not tested. A reader who finds a limit in the docs loses minutes. A reader who finds it in production loses days. The Differences from Tk page of ztk is a page of limits only. What Flight Manual is has a part "What it does not do".
Next: Reference and examples.