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
- Remove incorrect guideline about extracting interfaces to internal/interfaces
- Update Makefile for better formatting
- Fix documentation examples to use correct syntax
- Update integration test config
-**Use precise actors** - "MCP client" not "user" in technical contexts
@@ -184,11 +186,10 @@ cmd/mcp-front/ # Main application entry point
184
186
### Refactoring Guidelines
185
187
186
188
When refactoring for better design:
189
+
187
190
1.**Identify the core issue** - Don't just patch symptoms
188
191
2.**Use proper dependency injection** - Pass dependencies to constructors
189
-
3.**Extract interfaces to break circular dependencies** - Put in `internal/interfaces`
190
-
4.**Test the refactoring** - Ensure all tests still pass
191
-
5.**Update documentation** - Keep CLAUDE.md current with best practices
192
+
3.**Test the refactoring** - Ensure all tests still pass
192
193
193
194
### Security Boundaries
194
195
@@ -200,30 +201,32 @@ When refactoring for better design:
200
201
## Quick Reference Commands
201
202
202
203
```bash
203
-
# Build
204
-
go build -o mcp-front ./cmd/mcp-front
204
+
# Build everything
205
+
make build
205
206
206
-
# Test
207
-
go test ./...
208
-
go test ./integration -v
207
+
# Format everything
208
+
make format
209
209
210
-
# Lint
211
-
staticcheck ./...
210
+
# Lint everything
211
+
make lint
212
212
213
-
# Run locally
213
+
# Test mcp-front
214
+
go test ./internal/... -v
215
+
go test ./integration -v
216
+
217
+
# Run mcp-front locally
214
218
./mcp-front -config config.json
215
219
216
-
# Documentation site (from root)
217
-
make doc # Start dev server
218
-
make format # Format docs with Prettier
219
-
make build # Build static site
220
+
# Start docs dev server
221
+
make doc
220
222
```
221
223
222
224
## Documentation Site Guidelines
223
225
224
226
### Design Philosophy
225
227
226
228
The documentation site follows terse, to-the-point prose style (like early Stripe or Stainless docs):
229
+
227
230
- No bullet lists or tables in content
228
231
- Conversational yet technical tone
229
232
- Developer-to-developer communication
@@ -239,6 +242,7 @@ The documentation site follows terse, to-the-point prose style (like early Strip
239
242
### Technical Implementation
240
243
241
244
**Structure** (docs-site/):
245
+
242
246
```
243
247
src/
244
248
├── components/
@@ -252,6 +256,7 @@ src/
252
256
```
253
257
254
258
**Key Features**:
259
+
255
260
- Starlight theme with custom components and CSS overrides
256
261
- Proper light/dark mode with automatic logo switching
257
262
- 12-second animation cycle for subtle mascot behavior
@@ -260,26 +265,29 @@ src/
260
265
### Animation Details
261
266
262
267
The animated logo creates a face-like character:
268
+
263
269
-**Eyes**: Left/right translation (1px) with synchronized movement
264
-
-**Nose**: Subtle rotation (-1deg/+1deg) following eye direction
270
+
-**Nose**: Subtle rotation (-1deg/+1deg) following eye direction
265
271
-**Blinking**: Vertical scale (scaleY 0.1) with step-like timing for natural effect
266
272
-**Timing**: 12-second cycle for easter egg discovery, not attention-grabbing
267
273
268
274
### Color Management
269
275
270
276
**CSS Custom Properties**:
277
+
271
278
```css
272
279
:root {
273
-
--sl-color-accent: #FF6B6B; /* Light mode */
280
+
--sl-color-accent: #ff6b6b;/* Light mode */
274
281
}
275
282
276
-
[data-theme='dark'] {
277
-
--sl-color-accent: #FF6B6B; /* Buttons */
278
-
--sl-color-text-accent: #333333; /* Text on red backgrounds */
283
+
[data-theme="dark"] {
284
+
--sl-color-accent: #ff6b6b;/* Buttons */
285
+
--sl-color-text-accent: #333333; /* Text on red backgrounds */
279
286
}
280
287
```
281
288
282
289
**Specific Overrides**:
290
+
283
291
- GitHub icon: White in dark mode
284
292
- Sidebar selection: Readable contrast
285
293
- Anchor links: Light gray in dark mode
@@ -289,26 +297,30 @@ The animated logo creates a face-like character:
289
297
### Content Guidelines
290
298
291
299
**Configuration Examples**:
300
+
292
301
- Always use `{"$env": "VAR"}` syntax, never bash `$VAR`
293
302
- Match actual Go implementation exactly
294
303
- Use realistic service names (e.g., "linear" not "database")
295
304
- Include all required fields (version, transportType, etc.)
296
305
297
306
**Writing Style**:
307
+
298
308
- Flowing prose, not lists
299
-
- Explain the "why" not just "how"
309
+
- Explain the "why" not just "how"
300
310
- Assume developer audience
301
311
- Keep it concise but complete
302
312
303
313
### Pull Request Guidelines
304
314
305
315
**PR Titles**: Use clear, descriptive titles focused on the change impact, not just restating commit messages. Examples:
316
+
306
317
- ❌ "feat: add message endpoint support for SSE MCP servers"
307
318
- ✅ "Add SSE message endpoint support"
308
-
- ❌ "fix: implement session-specific tool registration for stdio clients"
319
+
- ❌ "fix: implement session-specific tool registration for stdio clients"
309
320
- ✅ "Fix stdio session tool handler conflicts"
310
321
311
322
**PR Descriptions**: Write terse prose for humans, not documentation. Avoid bullet lists unless they add genuine value. Focus on the problem solved and solution approach:
323
+
312
324
- Explain what was broken and how it's fixed
313
325
- Use conversational, developer-to-developer tone
314
326
- Skip implementation details unless critical for review
0 commit comments