Skip to content

Commit 2f50aac

Browse files
authored
Merge pull request #1075 from DuendeSoftware/mb/review
Add documentation review guidelines to `.github/instructions` and align README writing style section
2 parents 9119cb1 + 12078aa commit 2f50aac

2 files changed

Lines changed: 67 additions & 5 deletions

File tree

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
---
2+
applyTo: "astro/src/content/**/*.{md,mdx}"
3+
---
4+
5+
# Documentation Review Guidelines
6+
7+
## Purpose
8+
9+
Review documentation for Duende Software products (IdentityServer, BFF, etc.). Focus on writing quality, accuracy, and consistency with the project's authoring standards.
10+
11+
## Writing Style
12+
13+
* Tone: friendly, educational, patient — "a senior engineer sitting next to you helping with your homework."
14+
* Use active voice. "Enable" not "Enabled" or "Enabling".
15+
* Use second person: "you" is the reader, "we" is Duende Software.
16+
* Sentence case in body text. Title Case for titles.
17+
* Use the Oxford comma.
18+
* Avoid filler words: "very", "simple", "easy", "just".
19+
* Prefer plain words: "use" not "utilize", "set up" not "facilitate", "help" not "assist", "about" not "regarding".
20+
* Keep it concise. Don't pad. Longer isn't better.
21+
* Explain *why* something works, not just *what* to change.
22+
* Expand acronyms on first use: "Multi-Factor Authentication (MFA)".
23+
* If it sounds like a robot wrote it, flag it.
24+
25+
## Frontmatter
26+
27+
* Must have `title`, `description`, and `date`. Prefer `YYYY-MM-DD`, but do not flag other Astro/Starlight-accepted date formats already used in this repo (for example, full ISO 8601 timestamps).
28+
* May have `sidebar` with `label` and `order`. For long `title`, the `label` is used as a shorter entry in the navigation bar, and should be shorter than `title`.
29+
30+
## Linking Rules
31+
32+
* Prefer internal links over external links.
33+
* Internal links must start at the content root (e.g. `/identityserver/troubleshooting/index.md`) and include the `.md` or `.mdx` extension.
34+
* External links must use HTTPS.
35+
* Link relevant text: prefer `learn more about [improving sign-in]` over `click [here]`.
36+
* Long links (75+ chars) or repeated links should use markdown anchor syntax at the bottom of the file.
37+
* When linking externally, include a sentence about what the reader will find.
38+
39+
## Markdown Style
40+
41+
* Use `*` for unordered lists, not `-`.
42+
* Use inline links `[text](url)` unless the link is repeated or very long.
43+
* Internal links must include the file extension (`.md` or `.mdx`).
44+
45+
## Code Blocks
46+
47+
* Use triple backticks with an appropriate language identifier. Common identifiers used in this repo include `csharp`, `bash`, `powershell`, `shell`, `sh`, `json`, `html`, `javascript`, `typescript`, `css`, `razor`, `xml`, `sql`, `sqlite`, `txt`, `diff`, and `mermaid`.
48+
* Prefer `csharp` over `cs` for C#.
49+
* Add a title as a comment in the first line (e.g. `// Program.cs`).
50+
* Code should not require horizontal scrolling — keep it concise.
51+
* C# examples should use latest syntax (top-level statements, collection expressions).
52+
* Examples should be runnable and complete — "copy-paste from docs" is the goal.
53+
* Use backticks for inline references to properties, classes, symbols, and values (including HTTP status codes like `404`).
54+
* Avoid excessive indentation in code blocks; use column 0 unless indentation is needed to nest under lists or MDX components.
55+
* Mention NuGet packages with `dotnet add package ...` in a `bash` block and link to the NuGet Gallery.
56+
57+
## Redirects
58+
59+
* When a page is moved, check that `redirect_from` frontmatter is present with the old path.

README.md

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -111,14 +111,18 @@ WebStorm has Grazie as a built-in spell checker and grammar checker, and support
111111

112112
### Writing Style
113113

114+
* General style: "big brother sitting next to you helping with your homework." Friendly, educational, patient. You're a senior engineer who has seen this before and wants to help the reader understand, not just find a quick fix.
114115
* Use the active voice. For example, use "Enable" instead of "Enabled" or "Enabling".
115116
* Use the second person ("you" not "I" or "we"). "You" is the reader of the documentation. "We" is Duende Software.
116117
* Use sentence case in text. Titles use Title Case.
117118
* Use the Oxford comma.
118119
* Avoid words like "very", "simple", "easy", ...
119120
* "As well as" can be written as "and".
120-
* Avoid flowery language.
121+
* Use plain words: "use" not "utilize", "set up" not "facilitate", "help" not "assist", "about" not "regarding", ... (unless technically precise).
122+
* Avoid flowery language. Keep it concise. Answer thoroughly, but don't pad. Longer isn't better.
123+
* Educational, not pedantic: Explain *why* something works, not just *what* to change. Don't over-explain things that are likely already known. When in doubt, include some basic info and reference relevant other sources with more background.
121124
* When using acronyms, use the full form with parentheses the first time you use it. For example, use "Multi-Factor Authentication (MFA)" instead of "MFA".
125+
* Read it out loud. If it sounds like a robot wrote it, rewrite it.
122126

123127
### Linking Rules
124128

@@ -136,12 +140,11 @@ WebStorm has Grazie as a built-in spell checker and grammar checker, and support
136140
* Use `*` for lists. Do not use `-`.
137141
* Use `[link title](https://example.com)` for links, avoid reference-style links unless you need to repeat the same link multiple times.
138142
* For internal links, always include the extension (e.g. `.md` or `.mdx`)
139-
* Prefer `csharp` over `cs` to set the language for C# code blocks.
140143

141144
### Code Block Style
142145

143-
* Use triple backticks to enclose code blocks.
144-
* Use a language identifier to specify the language (e.g. `csharp`, `bash`, `json`, `html`, `javascript`, `typescript`, `css`, `json`)
146+
* Use triple backticks with an appropriate language identifier. Common identifiers used in this repo include `csharp`, `bash`, `powershell`, `shell`, `sh`, `json`, `html`, `javascript`, `typescript`, `css`, `razor`, `xml`, `sql`, `sqlite`, `txt`, `diff`, and `mermaid`.
147+
* Prefer `csharp` over `cs` to set the language for C# code blocks.
145148
* Add a title to the code block. You can do this adding the title as a comment in the first line of the code block (e.g. `// Program.cs`).
146149
* Use [expressive code features](https://starlight.astro.build/guides/authoring-content/#expressive-code-features).
147150
* Readers should not need to scroll horizontally to read a code example. Simplify and condense the code as much as possible.
@@ -151,7 +154,7 @@ WebStorm has Grazie as a built-in spell checker and grammar checker, and support
151154
* Mention NuGet packages as a `bash` code block showing how to install it (`dotnet add package ...`). Link to the NuGet Gallery.
152155
* When referencing a property, field, class, or other symbol in text, use the `test` format instead of _test_.
153156
* Values should also be back-ticked, especially HTTP Status codes like `404` or `401`.
154-
* Make sure code blocks start at the very first character space and don't have excessive starting padding.
157+
* Avoid excessive indentation in code blocks; use column 0 unless indentation is needed to nest under lists or MDX components.
155158

156159
### Frontmatter Rules
157160

0 commit comments

Comments
 (0)