Skip to content

Commit 71ef931

Browse files
committed
Enhance documentation guidelines for Nextra usage in CONTRIBUTING.md, SKILL.md, and related references
- Added instructions to utilize existing Nextra Markdown, MDX, and components for styling and layout before proposing custom solutions. - Clarified that changes to theme, layout, route, component, or CSS should not be included in content-only documentation updates. - Emphasized the need to create separate Linear tickets for any required Nextra functionality not currently supported.
1 parent 4849bb6 commit 71ef931

5 files changed

Lines changed: 30 additions & 1 deletion

File tree

CONTRIBUTING.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,10 @@ Sidebar order comes from the nearest `_meta.ts` file in the content tree. If you
5959

6060
Flat legacy redirects, such as `/docs/obsidian/<slug>` to `/docs/obsidian/<section>/<slug>`, are maintained in `apps/website/docsRouteMap.ts`.
6161

62+
Use existing Nextra Markdown, MDX, and `nextra/components` features for styling and layout before proposing anything custom. For example, use Nextra callouts, cards, steps, tabs, tables, and file trees when those fit the content.
63+
64+
If the docs need a styling or presentation feature that Nextra does not currently provide, create a separate Linear ticket to add that Nextra functionality. Do not include theme, layout, route, component, or CSS changes in a content-only docs update.
65+
6266
Detailed guidance for plugin docs lives next to the update-user-docs skill:
6367

6468
- **[llm-authoring-guide.md](./skills/update-user-docs/references/llm-authoring-guide.md)** - a short guide non-devs can give to an LLM before asking it to write or update docs

skills/update-user-docs/SKILL.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@ If no argument is provided, use the current branch's diff against main, commit m
1919
- Put Roam docs under `apps/website/content/roam/**`.
2020
- Do not edit legacy docs route shells or deleted legacy docs paths such as `apps/website/app/(docs)/docs/*/pages`, `docMap.ts`, `navigation.ts`, or `sharedPages`.
2121
- Do not update runtime code, app routes, or package interfaces unless the dev explicitly asks for that separately.
22+
- Use existing Nextra Markdown, MDX, and `nextra/components` features before proposing custom styling or layout.
23+
- Do not add or change theme, layout, route, component, or CSS code while adding documentation content. If existing Nextra features are not enough, flag the author to create a separate Linear ticket for new Nextra functionality.
2224

2325
## When to Run
2426

skills/update-user-docs/references/doc-conventions.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,22 @@ published: true
3131

3232
Use sentence case for page titles unless the title includes an official product name, plugin name, or UI label.
3333

34+
## Nextra styling and formats
35+
36+
Use existing Nextra Markdown, MDX, and `nextra/components` features before proposing custom styling.
37+
38+
Good first choices include:
39+
40+
- Standard Markdown headings, lists, links, tables, and code fences
41+
- Nextra `Callout` for warnings, tips, notes, and important context
42+
- Nextra `Cards` for small sets of high-level navigation options
43+
- Nextra `Steps` for ordered setup or workflow instructions
44+
- Nextra `Tabs` for compact platform or mode variants
45+
- Nextra `Table` and `FileTree` when structured data or file paths need clearer presentation
46+
47+
Do not change docs structural code, theme files, route shells, app layouts, shared components, or CSS as part of adding content.
48+
If the content needs a styling or presentation feature that existing Nextra features cannot support, stop and flag the author to create a separate Linear ticket for adding that Nextra functionality.
49+
3450
## Links
3551

3652
- Prefer absolute docs routes for cross-page links, such as `/docs/obsidian/core-features/node-tags`.

skills/update-user-docs/references/llm-authoring-guide.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,14 @@ Use these paths:
1313
- Sidebar order: nearest _meta.ts file
1414
- Flat legacy redirects: apps/website/docsRouteMap.ts
1515
16-
Do not edit route shells or legacy docs paths. Do not use app/(docs)/docs/*/pages, docMap.ts, navigation.ts, or sharedPages.
16+
Use existing Nextra Markdown, MDX, and nextra/components features first for styling and layout, such as Callout, Cards, Steps, Tabs, Table, and FileTree when appropriate.
17+
18+
Do not edit route shells, theme/layout code, shared components, CSS, or legacy docs paths. Do not use app/(docs)/docs/*/pages, docMap.ts, navigation.ts, or sharedPages.
1719
1820
If adding a page, choose the right platform section, create a kebab-case .md or .mdx file, update the nearest _meta.ts, and update docsRouteMap.ts only when a flat /docs/<platform>/<slug> redirect should exist.
1921
22+
If existing Nextra features are not enough for the requested styling, do not implement new styling in the docs change. Ask for a separate Linear ticket to add the needed Nextra functionality.
23+
2024
For screenshots, use real files in apps/website/public/docs/<platform>/ when available. If screenshots are missing, add an HTML TODO comment and list the needed screenshots in your summary. Do not add broken placeholder images.
2125
2226
Before finishing, verify links, sidebar registration, route redirects, and stale legacy path references.
@@ -65,6 +69,7 @@ If the screenshot is not available yet, add a comment like:
6569
- Docs edits are under `apps/website/content/**`.
6670
- New pages are registered in the nearest `_meta.ts`.
6771
- Needed flat redirects are in `apps/website/docsRouteMap.ts`.
72+
- Styling uses existing Nextra features and does not change structural code.
6873
- New links resolve to existing routes or files.
6974
- Screenshot TODOs are comments, not broken images.
7075
- No positive instructions point to legacy docs paths.

skills/update-user-docs/references/scope-detection.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@ Use this question to determine whether a code change requires a documentation up
2323

2424
If no docs update is needed, inform the dev and stop.
2525

26+
If a docs content request requires new styling, layout, component, theme, route, or CSS behavior that existing Nextra features cannot provide, do not fold that work into the docs content update. Flag it as a separate Linear ticket for adding new Nextra functionality.
27+
2628
## File path to docs scope mapping
2729

2830
| Changed file path pattern | Docs scope | Target docs location |

0 commit comments

Comments
 (0)