Skip to content

Commit be80310

Browse files
authored
Refresh, unify and add to AI rules (#1236)
1 parent 5de7919 commit be80310

File tree

4 files changed

+85
-134
lines changed

4 files changed

+85
-134
lines changed

.cursor/rules/docs.mdc

Lines changed: 2 additions & 64 deletions
Original file line numberDiff line numberDiff line change
@@ -1,68 +1,6 @@
11
---
2-
description:
2+
description:
33
globs: docs/*
44
alwaysApply: false
55
---
6-
# Cursor rules for Windmill documentation
7-
8-
These guidelines ensure consistency and quality when writing or modifying Windmill documentation.
9-
10-
## Content
11-
- The doc should focus on the user experience, not on the engineering behind it, unless it's important (e.g. feature related to performance)
12-
13-
## File structure and naming
14-
15-
- Use `.mdx` extension for documentation files
16-
- Main section pages should be named `index.mdx`
17-
- Folders should follow numeric prefixing for ordering (e.g., `0_scripts_quickstart`, `1_typescript_quickstart`)
18-
- Use underscores to separate words in file and folder names
19-
20-
## Markdown formatting
21-
22-
- Use proper heading hierarchy (# for main title, ## for sections, etc.)
23-
- Include relevant imports at the top of the file
24-
- Use code blocks with appropriate language specification (`ts, `python, etc.)
25-
- Avoid bold font, unless already used in the document
26-
- Titles, subtiles and docs in general follow sentence case ('Like this')
27-
28-
## Component usage
29-
30-
- Import and use DocCard components for navigation links
31-
- Follow the grid layout pattern for card navigation (typically 2 columns)
32-
- Use video elements with proper className for tutorials
33-
34-
## Media and assets
35-
36-
- Store images in the same directory as the related MDX file
37-
- Include both PNG and optimized WebP versions of images
38-
- Use meaningful names for image files that describe their content
39-
- Apply proper className to media elements for consistent styling
40-
- If a file / illustration / video would be useful but you don't have it, add a placeholder in comment to the file
41-
42-
## Content organization
43-
44-
- Each major feature has its own directory
45-
- Content progresses from basic to advanced concepts
46-
- Quickstart guides should be concise and focused on immediate results
47-
- Link to related documentation using relative paths
48-
- If a new page is added, make sure it appears in sidebars.js and check if its worth adding to core_concepts/index.mdx
49-
50-
## Cross-referencing
51-
52-
- Use relative paths for internal links (e.g., `../../8_triggers/index.mdx`)
53-
- Reference to useful pages using DocCard components
54-
- Maintain consistent linking patterns throughout documentation
55-
- Also when adding a feature, you can reference its dedicated page from related pages, using backink
56-
57-
## Code examples
58-
59-
- Include complete, working code examples that can be copied directly
60-
- Add explanatory comments to complex code sections
61-
- Use consistent indentation and formatting in code blocks
62-
- Show both input and expected output where appropriate
63-
64-
## Metadata and SEO
65-
66-
- URLs are derived from the file or folder name
67-
- Use descriptive titles that include keywords
68-
- If a new page is to be created, keep URLs clean and descriptive
6+
Instructions are in @AGENTS.md

AGENTS.md

Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
# AI rules for Windmill documentation
2+
3+
These guidelines ensure consistency and quality when writing or modifying Windmill documentation.
4+
5+
## Content
6+
7+
- The doc should focus on the user experience, not on the engineering behind it, unless it's important (e.g. feature related to performance)
8+
- **Before writing documentation, review @writing_style_guide.md for guidance about how to write good documentation**
9+
10+
## File structure and naming
11+
12+
- Use `.mdx` extension for documentation files
13+
- Main section pages should be named `index.mdx`
14+
- Folders should follow numeric prefixing for ordering (e.g., `0_scripts_quickstart`, `1_typescript_quickstart`)
15+
- Use underscores to separate words in file and folder names
16+
17+
## Markdown formatting
18+
19+
- Use proper heading hierarchy (# for main title, ## for sections, etc.)
20+
- Include relevant imports at the top of the file
21+
- Use code blocks with appropriate language specification (`ts, `python, etc.)
22+
- Avoid bold font, unless already used in the document
23+
- Titles, subtiles and docs in general follow sentence case ('Like this')
24+
- On docs, nothing shouldfollow title case ('Like This')
25+
26+
## Component usage
27+
28+
- Import and use DocCard components for navigation links
29+
- Follow the grid layout pattern for card navigation (typically 2 columns)
30+
- Use video elements with proper className for tutorials
31+
- Import and use Tabs and TabItem components for tabs (for example to show code examples in different languages)
32+
33+
## Media and assets
34+
35+
- Store images in the same directory as the related MDX file
36+
- Include both PNG and optimized WebP versions of images
37+
- Use meaningful names for image files that describe their content
38+
- Apply proper className to media elements for consistent styling
39+
- If a file / illustration / video would be useful but you don't have it, add a placeholder in comment to the file
40+
41+
## Content organization
42+
43+
- Each major feature has its own directory
44+
- Content progresses from basic to advanced concepts
45+
- Quickstart guides should be concise and focused on immediate results
46+
- Link to related documentation using relative paths
47+
- If a new page is added, make sure it appears in sidebars.js and check if its worth adding to core_concepts/index.mdx
48+
- New features shall have a dedicated changelog page and directory, like [this](./changelog/2025-08-19-kubernetes-native-autoscaling/index.md)
49+
- Changelogs should have tags (in Sentence case). In particular follow the color titles referenced in @src/theme/BlogPostItem/Container/index.js: (like 'App editor', 'Flow editor', 'Enterprise')
50+
- Major features shall be referenced in the [features list](./src/components/pricing/FeatureList.js), in particular if they are Enterprise features
51+
52+
## Cross-referencing and backlinks
53+
54+
- Use relative paths for internal links (e.g., `../../8_triggers/index.mdx`) when a concept is mentioned for the first time in the document and has not been backlinked yet in the document
55+
- Use absolute paths for external links (e.g., `https://www.docker.com/`) when linking to external websites and there is no dedicated page in the documentation
56+
- Using backlinks is very important to help users navigate the documentation and for SEO
57+
- Use backlinks in particular in the introduction of a document or section to reference the main related pages
58+
- When a page or section is deleted or renamed, update all backlinks to the new page or section
59+
- When a feature is Enterprise, Cloud or Pro only, mention it in the introduction of the document or section
60+
- Reference to main related pages using DocCard components
61+
- Reference to same-page sections using `#` anchors
62+
- Maintain consistent linking patterns throughout documentation
63+
- Also when adding a feature, reference its dedicated page from related pages, using backinks and relative paths
64+
65+
## Code examples
66+
67+
- Include complete, working code examples that can be copied directly
68+
- Add explanatory comments to complex code sections
69+
- Use consistent indentation and formatting in code blocks
70+
- Show both input and expected output where appropriate
71+
72+
## Metadata and SEO
73+
74+
- URLs are derived from the file or folder name (e.g. `windmilldocs/docs/core_concepts/20_jobs/index.mdx` will become `https://www.windmill.dev/docs/core_concepts/jobs`)
75+
- Use descriptive titles that include keywords
76+
- If a new page is to be created, keep URLs clean and descriptive

CLAUDE.md

Lines changed: 2 additions & 66 deletions
Original file line numberDiff line numberDiff line change
@@ -1,67 +1,3 @@
1-
# AI rules for Windmill documentation
1+
# Claude instructions
22

3-
These guidelines ensure consistency and quality when writing or modifying Windmill documentation.
4-
5-
## Content
6-
7-
- The doc should focus on the user experience, not on the engineering behind it, unless it's important (e.g. feature related to performance)
8-
- **Before writing new documentation, review @writing_style_guide.md for guidance about how to write good documentation**
9-
10-
## File structure and naming
11-
12-
- Use `.mdx` extension for documentation files
13-
- Main section pages should be named `index.mdx`
14-
- Folders should follow numeric prefixing for ordering (e.g., `0_scripts_quickstart`, `1_typescript_quickstart`)
15-
- Use underscores to separate words in file and folder names
16-
17-
## Markdown formatting
18-
19-
- Use proper heading hierarchy (# for main title, ## for sections, etc.)
20-
- Include relevant imports at the top of the file
21-
- Use code blocks with appropriate language specification (`ts, `python, etc.)
22-
- Avoid bold font, unless already used in the document
23-
- Titles, subtiles and docs in general follow sentence case ('Like this')
24-
25-
## Component usage
26-
27-
- Import and use DocCard components for navigation links
28-
- Follow the grid layout pattern for card navigation (typically 2 columns)
29-
- Use video elements with proper className for tutorials
30-
31-
## Media and assets
32-
33-
- Store images in the same directory as the related MDX file
34-
- Include both PNG and optimized WebP versions of images
35-
- Use meaningful names for image files that describe their content
36-
- Apply proper className to media elements for consistent styling
37-
- If a file / illustration / video would be useful but you don't have it, add a placeholder in comment to the file
38-
39-
## Content organization
40-
41-
- Each major feature has its own directory
42-
- Content progresses from basic to advanced concepts
43-
- Quickstart guides should be concise and focused on immediate results
44-
- Link to related documentation using relative paths
45-
- If a new page is added, make sure it appears in sidebars.js and check if its worth adding to core_concepts/index.mdx
46-
- Major features shall have a dedicated changelog page and directory, like [this](./changelog/2025-08-19-kubernetes-native-autoscaling/index.md).
47-
- Major features shall be referenced in the [features list](./src/components/pricing/FeatureList.js).
48-
49-
## Cross-referencing
50-
51-
- Use relative paths for internal links (e.g., `../../8_triggers/index.mdx`)
52-
- Reference to useful pages using DocCard components
53-
- Maintain consistent linking patterns throughout documentation
54-
- Also when adding a feature, you can reference its dedicated page from related pages, using backink
55-
56-
## Code examples
57-
58-
- Include complete, working code examples that can be copied directly
59-
- Add explanatory comments to complex code sections
60-
- Use consistent indentation and formatting in code blocks
61-
- Show both input and expected output where appropriate
62-
63-
## Metadata and SEO
64-
65-
- URLs are derived from the file or folder name
66-
- Use descriptive titles that include keywords
67-
- If a new page is to be created, keep URLs clean and descriptive
3+
Instructions are in @AGENTS.md

writing_style_guide.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
# Claude writing style guide
1+
# Writing style guide
22

3-
This file contains writing style guidance when creating Windmill documentation. Review this guide before writing new documentation.
3+
This file contains writing style guidance when creating Windmill documentation. Review this guide before writing documentation.
44

55
## General writing style issues
66

@@ -14,9 +14,10 @@ This file contains writing style guidance when creating Windmill documentation.
1414
- Too long and verbose for technical documentation
1515
- Marketing language like "This intelligent feature" sounds promotional rather than technical
1616
- Users prefer concise, direct explanations over flowery descriptions
17+
- No backlinks to other pages of documentation
1718

1819
**Better approach:**
1920

2021
- Keep descriptions short and technical
21-
- Focus on what the feature does, not how "intelligent" or "smart" it is
22-
- Use straightforward language: "Windmill can auto-fill script and flow inputs using AI" instead of verbose marketing copy
22+
- Focus on what the feature does and how to use it, not how "intelligent" or "smart" it is
23+
- Use straightforward language: "Windmill can auto-fill [script](../script_editor/index.mdx) and [flow](../flows/flow_editor/index.mdx) inputs using AI" instead of verbose marketing copy

0 commit comments

Comments
 (0)