You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[](https://github.com/przeprogramowani/ai-rules-builder/actions/workflows/master.yml)
8
-
9
-

10
-
11
-
👉 [10xRules.ai](https://10xrules.ai)
12
-
13
-
Create so called "rules for AI" written in Markdown, used by tools such as GitHub Copilot, Cursor and Windsurf, through an interactive, visual interface.
14
-
15
-
## Features
16
-
17
-
-**Build AI Rules:** Create customized rule sets for different editors (Copilot, Cursor, Windsurf)
18
-
-**Export Options:** Easily copy to clipboard or download as markdown files
19
-
-**Smart Import:** Automatically generate rules by dropping package.json or requirements.txt files
20
-
21
-
## Getting Started
22
-
23
-
1.**Installation**
24
-
25
-
```bash
26
-
npm install
27
-
```
28
-
29
-
2.**Development**
30
-
31
-
```bash
32
-
npm run dev
33
-
```
34
-
35
-
3.**Build**
36
-
```bash
37
-
npm run build
38
-
```
39
-
40
-
## Tech Stack
41
-
42
-
- Astro 5
43
-
- TypeScript 5
44
-
- React 18.3
45
-
- Tailwind 4
46
-
- Zustand
47
-
- Lucide React
48
-
49
-
### Feature Flags
50
-
51
-
The project uses a feature flags system to separate deployments from releases. Feature flags can be used to control functionality availability based on the environment (`local`, `integration`, `prod`). The system supports flags for:
52
-
53
-
- API endpoints
54
-
- Astro pages
55
-
- UI components visibility
56
-
57
-
For detailed documentation about feature flags implementation, see `.ai/feature-flags.md`.
58
-
59
-
### Testing
60
-
61
-
This project uses a comprehensive testing stack including unit tests and end-to-end tests.
62
-
63
-
### Unit Testing with Vitest
64
-
65
-
Unit tests are implemented using Vitest with JSDOM for browser environment simulation and React Testing Library for component testing.
66
-
67
-
Available commands:
68
-
69
-
```bash
70
-
# Run unit tests
71
-
npm run test
72
-
73
-
# Run tests in watch mode
74
-
npm run test:watch
75
-
76
-
# Run tests with UI
77
-
npm run test:ui
78
-
79
-
# Generate coverage report
80
-
npm run test:coverage
81
-
```
82
-
83
-
### End-to-End Testing with Playwright
84
-
85
-
E2E tests are implemented using Playwright with the Page Object Model pattern for maintainable tests.
86
-
87
-
Available commands:
88
-
89
-
```bash
90
-
# Run E2E tests
91
-
npm run test:e2e
92
-
93
-
# Run E2E tests with UI
94
-
npm run test:e2e:ui
95
-
96
-
# Generate test code with codegen
97
-
npm run test:e2e:codegen
98
-
```
99
-
100
-
### Test Structure
101
-
102
-
-`tests/unit/` - Unit tests
103
-
-`tests/setup/` - Test setup files
104
-
-`e2e/` - End-to-end tests
105
-
-`e2e/page-objects/` - Page Object Model classes
106
-
-`e2e/fixtures/` - Test fixtures and data
107
-
108
-
### CI/CD Integration
109
-
110
-
Tests are automatically run in the CI/CD pipeline using GitHub Actions. See `.github/workflows/tests.yml` for configuration.
111
-
112
-
## Contributions
113
-
114
-
Send updates to:
115
-
116
-
-`src/data/dictionaries.ts`
117
-
-`src/data/rules/...`
118
-
119
-
Important: Introduce translations for new rules in `src/i18n/translations.ts`, otherwise the unit test will fail.
120
-
121
-
## How to Write Effective Rules
122
-
123
-
When contributing new rules, please:
124
-
125
-
-**Be specific:** "Use React.memo for expensive components" not "Optimize components"
126
-
-**Make it actionable:** Provide clear guidance that can be immediately applied
127
-
-**Include placeholders:** Use `{{placeholder_text}}` for project-specific values
128
-
-**Follow conventions:** Match the style and structure of existing rules
129
-
-**Focus on best practices:** Rules should represent industry standards, not personal preferences
130
-
131
-
See examples in `src/data/rules/` directory for each technology stack.
132
-
133
-
---
134
-
135
-
[10xDevs](https://10xdevs.pl) - launching soon 🚀
136
-
137
-
## Contributors ✨
138
-
139
-
Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/docs/en/emoji-key)):
140
-
5
+
<!-- ALL-CONTRIBUTORS-BADGE:END -->
6
+
7
+
[](https://github.com/przeprogramowani/ai-rules-builder/actions/workflows/master.yml)
8
+
9
+

10
+
11
+
👉 [10xRules.ai](https://10xrules.ai)
12
+
13
+
Create so called "rules for AI" written in Markdown, used by tools such as GitHub Copilot, Cursor and Windsurf, through an interactive, visual interface.
14
+
15
+
## Features
16
+
17
+
-**Build AI Rules:** Create customized rule sets for different editors (Copilot, Cursor, Windsurf)
18
+
-**Export Options:** Easily copy to clipboard or download as markdown files
19
+
-**Smart Import:** Automatically generate rules by dropping package.json or requirements.txt files
20
+
-**Editor Integration:** Provides programmatic access to rules via an [MCP Server](./mcp-server/README.md) for integration with AI assistants in editors like Cursor.
21
+
22
+
## Getting Started
23
+
24
+
1.**Installation**
25
+
26
+
```bash
27
+
npm install
28
+
```
29
+
30
+
2.**Development**
31
+
32
+
```bash
33
+
npm run dev
34
+
```
35
+
36
+
3.**Build**
37
+
```bash
38
+
npm run build
39
+
```
40
+
41
+
## Tech Stack
42
+
43
+
- Astro 5
44
+
- TypeScript 5
45
+
- React 18.3
46
+
- Tailwind 4
47
+
- Zustand
48
+
- Lucide React
49
+
50
+
## Project Components
51
+
52
+
This repository contains multiple key components:
53
+
54
+
-**AI Rules Builder UI (Root):** The main Astro/React application providing the web interface for creating and managing AI rules.
55
+
-**MCP Server (`./mcp-server`):** A Cloudflare Worker implementing the Model Context Protocol (MCP). This server allows AI assistants (like Cursor, Claude, etc.) to programmatically access the defined AI rules via specific tools (`listAvailableRules`, `getRuleContent`). This enables integration with editors for fetching context-aware coding guidelines. For detailed setup, usage, and planned features, see the [MCP Server README](./mcp-server/README.md).
56
+
57
+
### Feature Flags
58
+
59
+
The project uses a feature flags system to separate deployments from releases. Feature flags can be used to control functionality availability based on the environment (`local`, `integration`, `prod`). The system supports flags for:
60
+
61
+
- API endpoints
62
+
- Astro pages
63
+
- UI components visibility
64
+
65
+
For detailed documentation about feature flags implementation, see `.ai/feature-flags.md`.
66
+
67
+
### Testing
68
+
69
+
This project uses a comprehensive testing stack including unit tests and end-to-end tests.
70
+
71
+
### Unit Testing with Vitest
72
+
73
+
Unit tests are implemented using Vitest with JSDOM for browser environment simulation and React Testing Library for component testing.
74
+
75
+
Available commands:
76
+
77
+
```bash
78
+
# Run unit tests
79
+
npm run test
80
+
81
+
# Run tests in watch mode
82
+
npm run test:watch
83
+
84
+
# Run tests with UI
85
+
npm run test:ui
86
+
87
+
# Generate coverage report
88
+
npm run test:coverage
89
+
```
90
+
91
+
### End-to-End Testing with Playwright
92
+
93
+
E2E tests are implemented using Playwright with the Page Object Model pattern for maintainable tests.
94
+
95
+
Available commands:
96
+
97
+
```bash
98
+
# Run E2E tests
99
+
npm run test:e2e
100
+
101
+
# Run E2E tests with UI
102
+
npm run test:e2e:ui
103
+
104
+
# Generate test code with codegen
105
+
npm run test:e2e:codegen
106
+
```
107
+
108
+
### Test Structure
109
+
110
+
-`tests/unit/` - Unit tests
111
+
-`tests/setup/` - Test setup files
112
+
-`e2e/` - End-to-end tests
113
+
-`e2e/page-objects/` - Page Object Model classes
114
+
-`e2e/fixtures/` - Test fixtures and data
115
+
116
+
### CI/CD Integration
117
+
118
+
Tests are automatically run in the CI/CD pipeline using GitHub Actions. See `.github/workflows/tests.yml` for configuration.
119
+
120
+
## Contributions
121
+
122
+
Send updates to:
123
+
124
+
-`src/data/dictionaries.ts`
125
+
-`src/data/rules/...`
126
+
127
+
Important: Introduce translations for new rules in `src/i18n/translations.ts`, otherwise the unit test will fail.
128
+
129
+
## How to Write Effective Rules
130
+
131
+
When contributing new rules, please:
132
+
133
+
-**Be specific:** "Use React.memo for expensive components" not "Optimize components"
134
+
-**Make it actionable:** Provide clear guidance that can be immediately applied
135
+
-**Include placeholders:** Use `{{placeholder_text}}` for project-specific values
136
+
-**Follow conventions:** Match the style and structure of existing rules
137
+
-**Focus on best practices:** Rules should represent industry standards, not personal preferences
138
+
139
+
See examples in `src/data/rules/` directory for each technology stack.
140
+
141
+
---
142
+
143
+
[10xDevs](https://10xdevs.pl) - launching soon 🚀
144
+
145
+
## Contributors ✨
146
+
147
+
Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/docs/en/emoji-key)):
148
+
141
149
<!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section -->
142
150
<!-- prettier-ignore-start -->
143
151
<!-- markdownlint-disable -->
@@ -156,6 +164,6 @@ Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/d
156
164
<!-- markdownlint-restore -->
157
165
<!-- prettier-ignore-end -->
158
166
159
-
<!-- ALL-CONTRIBUTORS-LIST:END -->
160
-
161
-
We're recognizing all contributors with [all-contributors](https://github.com/all-contributors/all-contributors). Feel invited to collaborate!
167
+
<!-- ALL-CONTRIBUTORS-LIST:END -->
168
+
169
+
We're recognizing all contributors with [all-contributors](https://github.com/all-contributors/all-contributors). Feel invited to collaborate!
0 commit comments