agents-config 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AGENTS.md +490 -0
- package/LICENSE +21 -0
- package/README.md +254 -0
- package/adapters/claude.template.md +77 -0
- package/adapters/codex.template.md +72 -0
- package/adapters/copilot.template.md +68 -0
- package/adapters/cursor.template.md +69 -0
- package/adapters/gemini.template.md +73 -0
- package/adapters/windsurf.template.md +81 -0
- package/bin/agents-init.js +699 -0
- package/bin/postinstall.js +28 -0
- package/instructions/development-standards.instructions.md +47 -0
- package/instructions/github-issue.instructions.md +324 -0
- package/instructions/github-release-notes.instructions.md +888 -0
- package/instructions/mui.instructions.md +50 -0
- package/instructions/storybook.instructions.md +55 -0
- package/instructions/web-interface-guidelines.instructions.md +331 -0
- package/package.json +56 -0
- package/prompts/create-pr.prompt.md +78 -0
- package/prompts/scaffold-component.prompt.md +57 -0
- package/rules/accessibility.md +36 -0
- package/rules/component-architecture.md +34 -0
- package/rules/gemini.md +547 -0
- package/rules/mui.md +491 -0
- package/rules/react-19-compiler.md +26 -0
- package/rules/spec-driven-development.md +36 -0
- package/rules/supabase.md +40 -0
- package/rules/tailwind-v4.md +29 -0
- package/rules/three-js-react.md +76 -0
- package/rules/web-performance.md +29 -0
- package/schemas/agents-project.schema.json +78 -0
- package/skills/accessibility-audit/SKILL.md +39 -0
- package/skills/integrate-gemini/SKILL.md +124 -0
- package/skills/scaffold-component/SKILL.md +77 -0
- package/skills/vercel-react-best-practices/AGENTS.md +2719 -0
- package/skills/vercel-react-best-practices/SKILL.md +125 -0
- package/skills/vercel-react-best-practices/rules/advanced-event-handler-refs.md +55 -0
- package/skills/vercel-react-best-practices/rules/advanced-use-latest.md +39 -0
- package/skills/vercel-react-best-practices/rules/async-api-routes.md +38 -0
- package/skills/vercel-react-best-practices/rules/async-defer-await.md +80 -0
- package/skills/vercel-react-best-practices/rules/async-dependencies.md +51 -0
- package/skills/vercel-react-best-practices/rules/async-parallel.md +28 -0
- package/skills/vercel-react-best-practices/rules/async-suspense-boundaries.md +99 -0
- package/skills/vercel-react-best-practices/rules/bundle-barrel-imports.md +59 -0
- package/skills/vercel-react-best-practices/rules/bundle-conditional.md +31 -0
- package/skills/vercel-react-best-practices/rules/bundle-defer-third-party.md +49 -0
- package/skills/vercel-react-best-practices/rules/bundle-dynamic-imports.md +35 -0
- package/skills/vercel-react-best-practices/rules/bundle-preload.md +50 -0
- package/skills/vercel-react-best-practices/rules/client-event-listeners.md +74 -0
- package/skills/vercel-react-best-practices/rules/client-localstorage-schema.md +71 -0
- package/skills/vercel-react-best-practices/rules/client-passive-event-listeners.md +48 -0
- package/skills/vercel-react-best-practices/rules/client-swr-dedup.md +56 -0
- package/skills/vercel-react-best-practices/rules/js-batch-dom-css.md +107 -0
- package/skills/vercel-react-best-practices/rules/js-cache-function-results.md +80 -0
- package/skills/vercel-react-best-practices/rules/js-cache-property-access.md +28 -0
- package/skills/vercel-react-best-practices/rules/js-cache-storage.md +70 -0
- package/skills/vercel-react-best-practices/rules/js-combine-iterations.md +32 -0
- package/skills/vercel-react-best-practices/rules/js-early-exit.md +50 -0
- package/skills/vercel-react-best-practices/rules/js-hoist-regexp.md +45 -0
- package/skills/vercel-react-best-practices/rules/js-index-maps.md +37 -0
- package/skills/vercel-react-best-practices/rules/js-length-check-first.md +49 -0
- package/skills/vercel-react-best-practices/rules/js-min-max-loop.md +82 -0
- package/skills/vercel-react-best-practices/rules/js-set-map-lookups.md +24 -0
- package/skills/vercel-react-best-practices/rules/js-tosorted-immutable.md +57 -0
- package/skills/vercel-react-best-practices/rules/rendering-activity.md +26 -0
- package/skills/vercel-react-best-practices/rules/rendering-animate-svg-wrapper.md +47 -0
- package/skills/vercel-react-best-practices/rules/rendering-conditional-render.md +40 -0
- package/skills/vercel-react-best-practices/rules/rendering-content-visibility.md +38 -0
- package/skills/vercel-react-best-practices/rules/rendering-hoist-jsx.md +46 -0
- package/skills/vercel-react-best-practices/rules/rendering-hydration-no-flicker.md +82 -0
- package/skills/vercel-react-best-practices/rules/rendering-svg-precision.md +28 -0
- package/skills/vercel-react-best-practices/rules/rendering-usetransition-loading.md +75 -0
- package/skills/vercel-react-best-practices/rules/rerender-defer-reads.md +39 -0
- package/skills/vercel-react-best-practices/rules/rerender-dependencies.md +45 -0
- package/skills/vercel-react-best-practices/rules/rerender-derived-state.md +29 -0
- package/skills/vercel-react-best-practices/rules/rerender-functional-setstate.md +74 -0
- package/skills/vercel-react-best-practices/rules/rerender-lazy-state-init.md +58 -0
- package/skills/vercel-react-best-practices/rules/rerender-memo-with-default-value.md +38 -0
- package/skills/vercel-react-best-practices/rules/rerender-memo.md +44 -0
- package/skills/vercel-react-best-practices/rules/rerender-simple-expression-in-memo.md +35 -0
- package/skills/vercel-react-best-practices/rules/rerender-transitions.md +40 -0
- package/skills/vercel-react-best-practices/rules/server-after-nonblocking.md +73 -0
- package/skills/vercel-react-best-practices/rules/server-auth-actions.md +96 -0
- package/skills/vercel-react-best-practices/rules/server-cache-lru.md +41 -0
- package/skills/vercel-react-best-practices/rules/server-cache-react.md +76 -0
- package/skills/vercel-react-best-practices/rules/server-dedup-props.md +65 -0
- package/skills/vercel-react-best-practices/rules/server-parallel-fetching.md +83 -0
- package/skills/vercel-react-best-practices/rules/server-serialization.md +38 -0
- package/skills/workflows/sdd-workflow.md +49 -0
- package/skills/workflows/setup-orchestration.md +18 -0
package/AGENTS.md
ADDED
|
@@ -0,0 +1,490 @@
|
|
|
1
|
+
# Agents guidelines when building React applications with AI-powered tools
|
|
2
|
+
|
|
3
|
+
**OBJECTIVE:**
|
|
4
|
+
Building production-ready React applications with TypeScript and AI-powered tools.
|
|
5
|
+
|
|
6
|
+
**REASON:**
|
|
7
|
+
Enables rapid prototyping and design collaboration while delivering production-quality, maintainable code.
|
|
8
|
+
|
|
9
|
+
**DESCRIPTION:**
|
|
10
|
+
Use these instructions when building React applications in TypeScript, independent of specific UI frameworks.
|
|
11
|
+
|
|
12
|
+
**INSTRUCTIONS:**
|
|
13
|
+
Create responsive, accessible React applications with TypeScript using strict configuration.
|
|
14
|
+
|
|
15
|
+
**IMPORTANT!** Before you start a task, or make a new change, follow these _rules_:
|
|
16
|
+
|
|
17
|
+
- DO NOT change the visual design, theme styling, or composition of the UI once a `checkpoint`, and/or a component or pattern has been established.
|
|
18
|
+
|
|
19
|
+
- DO NOT revert any "styling" (CSS/Layout) or "scripting" (TS/JSX) change intentionally by me.
|
|
20
|
+
|
|
21
|
+
- DO NOT make changes outside the scope of the requested feature, i.e., don't modify the main navigation when asked to build a data table.
|
|
22
|
+
|
|
23
|
+
- ALWAYS break out code into reusable components ready for export via ES module
|
|
24
|
+
|
|
25
|
+
- ALWAYS follow the [Component Architecture](./rules/component-architecture.md) folder-per-component pattern
|
|
26
|
+
|
|
27
|
+
- ALWAYS create SPEC.md before coding new features (see [Spec-Driven Development](./rules/spec-driven-development.md))
|
|
28
|
+
|
|
29
|
+
Include the following specifications:
|
|
30
|
+
|
|
31
|
+
1. **Accessibility & Performance**: Prioritize as first-class features. Follow [Web Interface Guidelines](./instructions/web-interface-guidelines.instructions.md):
|
|
32
|
+
- Semantic HTML (`<button>`, `<a>`, `<label>`, `<form>`)
|
|
33
|
+
- ARIA labels for icon-only buttons and form controls
|
|
34
|
+
- Keyboard navigation and visible focus states
|
|
35
|
+
- Screen reader support with `aria-live` for async updates
|
|
36
|
+
- No paste-blocking or zoom-disabling
|
|
37
|
+
- Images with explicit dimensions
|
|
38
|
+
|
|
39
|
+
2. **Adaptive Layout & Mobile-First UX**: Use CSS custom properties, Container Queries, and dynamic viewport units (`cqw`, `svh`) for responsive design. Implement touch-friendly interactions.
|
|
40
|
+
|
|
41
|
+
3. **TypeScript**: Use strict typing throughout. Define interfaces for component props. Avoid `any`.
|
|
42
|
+
|
|
43
|
+
4. **Component Structure**:
|
|
44
|
+
- One component per file with PascalCase filename (`.tsx`)
|
|
45
|
+
- Functional components with hooks
|
|
46
|
+
- Explicit prop types via interfaces
|
|
47
|
+
- `defaultProps` for optional props
|
|
48
|
+
- Named exports or single default export
|
|
49
|
+
|
|
50
|
+
5. **State Management**:
|
|
51
|
+
- Use `useState` and `useContext` for local/shared state
|
|
52
|
+
- Consider Context API for multi-level prop passing (2-3+ levels)
|
|
53
|
+
- URL state for filters, tabs, pagination, expanded panels (use libraries like `nuqs`)
|
|
54
|
+
|
|
55
|
+
6. **Styling**:
|
|
56
|
+
- Use a consistent CSS-in-JS solution (Emotion, styled-components) or utility-based CSS
|
|
57
|
+
- Create reusable design tokens (colors, typography, spacing)
|
|
58
|
+
- Support light/dark modes; persist user preference
|
|
59
|
+
- Avoid `transition: all`; list properties explicitly
|
|
60
|
+
- Honor `prefers-reduced-motion`
|
|
61
|
+
|
|
62
|
+
7. **Forms & Inputs**:
|
|
63
|
+
- Inputs require `<label>` or `aria-label`
|
|
64
|
+
- Use correct `type` and `inputmode`
|
|
65
|
+
- Include validation inline near fields
|
|
66
|
+
- Disable submit button during requests; show loading state
|
|
67
|
+
- Focus first error on submit
|
|
68
|
+
- No paste-blocking; allow autocomplete
|
|
69
|
+
|
|
70
|
+
8. **Icons**: Use inline SVG or icon libraries (e.g., Lucide). No webfont icons.
|
|
71
|
+
|
|
72
|
+
9. **Images**:
|
|
73
|
+
- Explicit `width` and `height` to prevent layout shift
|
|
74
|
+
- Lazy load below-fold images
|
|
75
|
+
- Preload critical above-fold images
|
|
76
|
+
|
|
77
|
+
10. **Performance**:
|
|
78
|
+
- Virtualize large lists (>50 items)
|
|
79
|
+
- Avoid layout reads in render (`getBoundingClientRect`, `offsetHeight`)
|
|
80
|
+
- Batch DOM operations
|
|
81
|
+
- Use uncontrolled inputs where possible
|
|
82
|
+
- Memoize expensive computations (`useMemo`, `useCallback`)
|
|
83
|
+
|
|
84
|
+
11. **Navigation & Deep Linking**:
|
|
85
|
+
- Use `<a>` or router `<Link>` (support Cmd/Ctrl+click)
|
|
86
|
+
- Sync URL with component state
|
|
87
|
+
- Support deep linking for all interactive features
|
|
88
|
+
|
|
89
|
+
12. **Destructive Actions**: Require confirmation modal or undo window. Never immediate.
|
|
90
|
+
|
|
91
|
+
13. **Testing & Documentation**:
|
|
92
|
+
- Unit tests for core components and utilities
|
|
93
|
+
- Visual regression tests when possible
|
|
94
|
+
- Storybook or equivalent for documentation
|
|
95
|
+
- Accessibility audits (WCAG)
|
|
96
|
+
|
|
97
|
+
14. **Web Standards Compliance**: Follow all guidelines in [Web Interface Guidelines](./instructions/web-interface-guidelines.instructions.md) for forms, focus, animations, content handling, hydration, and copy.
|
|
98
|
+
|
|
99
|
+
---
|
|
100
|
+
|
|
101
|
+
## Available Agents
|
|
102
|
+
|
|
103
|
+
### 1. Component Scaffolding Agent
|
|
104
|
+
**Purpose**: Create new React components following project architecture patterns
|
|
105
|
+
|
|
106
|
+
**Prompt**: Use [scaffold-component.prompt.md](./prompts/scaffold-component.prompt.md)
|
|
107
|
+
|
|
108
|
+
**Skill**: [scaffold-component](./skills/scaffold-component/SKILL.md)
|
|
109
|
+
|
|
110
|
+
**Capabilities**:
|
|
111
|
+
- Generates component following folder-per-component architecture
|
|
112
|
+
- Creates complete file structure: `.tsx`, `.stories.tsx`, `.mdx`, `index.ts`
|
|
113
|
+
- Applies Spec-Driven Development workflow
|
|
114
|
+
- Auto-detects framework (Tailwind, MUI, Vanilla CSS)
|
|
115
|
+
- Ensures accessibility standards and TypeScript strict typing
|
|
116
|
+
- Initializes component specification before implementation
|
|
117
|
+
|
|
118
|
+
**Required Inputs**:
|
|
119
|
+
- Component name (PascalCase)
|
|
120
|
+
- Component category (if applicable to project structure)
|
|
121
|
+
- Framework/styling approach
|
|
122
|
+
- Custom props/features needed
|
|
123
|
+
|
|
124
|
+
**Example**:
|
|
125
|
+
```
|
|
126
|
+
Create a StatusBadge component using Tailwind CSS
|
|
127
|
+
Category: dataDisplay
|
|
128
|
+
Features: status variants (success, warning, error, info), size variants
|
|
129
|
+
```
|
|
130
|
+
|
|
131
|
+
---
|
|
132
|
+
|
|
133
|
+
### 2. Accessibility Audit Agent
|
|
134
|
+
**Purpose**: Verify components and pages meet WCAG accessibility standards
|
|
135
|
+
|
|
136
|
+
**Skill**: [accessibility-audit](./skills/accessibility-audit/SKILL.md)
|
|
137
|
+
|
|
138
|
+
**Capabilities**:
|
|
139
|
+
- Scans components for WCAG violations
|
|
140
|
+
- Verifies semantic HTML structure
|
|
141
|
+
- Validates ARIA attributes and roles
|
|
142
|
+
- Checks keyboard navigation and focus management
|
|
143
|
+
- Validates color contrast ratios
|
|
144
|
+
- Tests screen reader compatibility
|
|
145
|
+
- Generates remediation plan
|
|
146
|
+
|
|
147
|
+
**Required Inputs**:
|
|
148
|
+
- Component or page to audit
|
|
149
|
+
- WCAG level target (A, AA, AAA)
|
|
150
|
+
- Specific concerns (keyboard, screen reader, color)
|
|
151
|
+
|
|
152
|
+
**Example**:
|
|
153
|
+
```
|
|
154
|
+
Audit Modal component for WCAG 2.1 Level AA compliance
|
|
155
|
+
Focus on: keyboard trap prevention, focus management, ARIA roles
|
|
156
|
+
Generate remediation plan with priority levels
|
|
157
|
+
```
|
|
158
|
+
|
|
159
|
+
---
|
|
160
|
+
|
|
161
|
+
### 3. AI Integration Agent (Gemini)
|
|
162
|
+
**Purpose**: Implement Google Gemini API integration with streaming and error handling
|
|
163
|
+
|
|
164
|
+
**Skill**: [integrate-gemini](./skills/integrate-gemini/SKILL.md)
|
|
165
|
+
|
|
166
|
+
**Capabilities**:
|
|
167
|
+
- Implements secure API key handling
|
|
168
|
+
- Sets up streaming response patterns
|
|
169
|
+
- Handles rate limiting and network errors
|
|
170
|
+
- Creates proper loading and streaming UI states
|
|
171
|
+
- Ensures AI attribution and safety requirements
|
|
172
|
+
- Implements TypeScript type safety
|
|
173
|
+
|
|
174
|
+
**Required Inputs**:
|
|
175
|
+
- Integration type (chat, completion, embedding, etc.)
|
|
176
|
+
- UI requirements for loading/streaming
|
|
177
|
+
- Error handling preferences
|
|
178
|
+
|
|
179
|
+
**Example**:
|
|
180
|
+
```
|
|
181
|
+
Add Gemini chat integration to ChatInterface component
|
|
182
|
+
Requirements: streaming responses, loading states, error recovery
|
|
183
|
+
Include: retry logic, rate limit handling, proper attribution
|
|
184
|
+
```
|
|
185
|
+
|
|
186
|
+
---
|
|
187
|
+
|
|
188
|
+
### 4. Performance Optimization Agent
|
|
189
|
+
**Purpose**: Analyze and optimize React component performance
|
|
190
|
+
|
|
191
|
+
**Skill**: [vercel-react-best-practices](./skills/vercel-react-best-practices/SKILL.md)
|
|
192
|
+
|
|
193
|
+
**Capabilities**:
|
|
194
|
+
- Applies Vercel React Best Practices (45 rules across 8 categories)
|
|
195
|
+
- Analyzes bundle size and tree-shaking opportunities
|
|
196
|
+
- Identifies re-render issues and optimization opportunities
|
|
197
|
+
- Implements memoization patterns (`React.memo`, `useMemo`, `useCallback`)
|
|
198
|
+
- Optimizes large list rendering with virtualization
|
|
199
|
+
- Reviews lazy loading and code splitting strategies
|
|
200
|
+
- Eliminates request waterfalls
|
|
201
|
+
- Optimizes async dependencies
|
|
202
|
+
|
|
203
|
+
**Required Inputs**:
|
|
204
|
+
- Component or feature to optimize
|
|
205
|
+
- Performance metrics to target
|
|
206
|
+
- Specific bottlenecks observed
|
|
207
|
+
- Priority level (quick wins vs deep optimization)
|
|
208
|
+
|
|
209
|
+
**Example**:
|
|
210
|
+
```
|
|
211
|
+
Optimize DataTable component for 10,000+ rows
|
|
212
|
+
Metrics: < 100ms initial render, < 50ms scroll lag
|
|
213
|
+
Implement: virtualization, memoization, lazy loading
|
|
214
|
+
Priority: Apply bundle optimization and re-render prevention patterns
|
|
215
|
+
```
|
|
216
|
+
|
|
217
|
+
---
|
|
218
|
+
|
|
219
|
+
### 5. Component Refactor Agent
|
|
220
|
+
**Purpose**: Refactor existing components to follow standards and best practices
|
|
221
|
+
|
|
222
|
+
**Process**: Follows [Spec-Driven Development](./skills/workflows/sdd-workflow.md) workflow
|
|
223
|
+
|
|
224
|
+
**Capabilities**:
|
|
225
|
+
- Creates or updates component spec before refactoring
|
|
226
|
+
- Updates components to latest framework patterns
|
|
227
|
+
- Applies TypeScript best practices
|
|
228
|
+
- Applies Vercel React Best Practices optimization rules
|
|
229
|
+
- Improves accessibility (ARIA labels, keyboard navigation)
|
|
230
|
+
- Optimizes performance (memoization, lazy loading)
|
|
231
|
+
- Maintains backward compatibility where possible
|
|
232
|
+
- Updates spec changelog with all changes
|
|
233
|
+
|
|
234
|
+
**Required Inputs**:
|
|
235
|
+
- Component to refactor
|
|
236
|
+
- Specific issues to address
|
|
237
|
+
- Breaking change tolerance (patch/minor/major)
|
|
238
|
+
- Target standards/patterns
|
|
239
|
+
|
|
240
|
+
**Example**:
|
|
241
|
+
```
|
|
242
|
+
Refactor UserProfile component to:
|
|
243
|
+
- Use latest React hooks patterns
|
|
244
|
+
- Add keyboard navigation
|
|
245
|
+
- Improve TypeScript types
|
|
246
|
+
- Apply memoization for expensive computations
|
|
247
|
+
Maintain backward compatibility (minor version bump)
|
|
248
|
+
```
|
|
249
|
+
|
|
250
|
+
---
|
|
251
|
+
|
|
252
|
+
### 6. Pull Request Agent
|
|
253
|
+
**Purpose**: Generate comprehensive PR descriptions from git commits
|
|
254
|
+
|
|
255
|
+
**Prompt**: Use [create-pr.prompt.md](./prompts/create-pr.prompt.md)
|
|
256
|
+
|
|
257
|
+
**Capabilities**:
|
|
258
|
+
- Analyzes git commit history and diffs
|
|
259
|
+
- Generates structured PR descriptions
|
|
260
|
+
- Includes summary, changes, testing notes, and breaking changes
|
|
261
|
+
- References related issues and tickets
|
|
262
|
+
- Follows conventional commit standards
|
|
263
|
+
- Provides migration guidance for breaking changes
|
|
264
|
+
|
|
265
|
+
**Required Inputs**:
|
|
266
|
+
- Commit SHA or range
|
|
267
|
+
- PR type (feature, fix, refactor, documentation)
|
|
268
|
+
- Related issue numbers
|
|
269
|
+
|
|
270
|
+
**Example**:
|
|
271
|
+
```
|
|
272
|
+
Generate PR description for last commit
|
|
273
|
+
Include: summary of changes, files affected, testing approach
|
|
274
|
+
Type: Feature enhancement
|
|
275
|
+
Related: Issue #123
|
|
276
|
+
```
|
|
277
|
+
|
|
278
|
+
---
|
|
279
|
+
|
|
280
|
+
### 7. Specification Development Agent
|
|
281
|
+
**Purpose**: Create technical specifications before implementation
|
|
282
|
+
|
|
283
|
+
**Workflow**: [sdd-workflow.md](./skills/workflows/sdd-workflow.md)
|
|
284
|
+
|
|
285
|
+
**Capabilities**:
|
|
286
|
+
- Creates comprehensive component/feature specifications
|
|
287
|
+
- Documents goals, interface, technical implementation
|
|
288
|
+
- Defines accessibility and performance requirements
|
|
289
|
+
- Establishes implementation checklist
|
|
290
|
+
- Maintains changelog of spec updates
|
|
291
|
+
- Ensures alignment with [spec-driven-development.md](./rules/spec-driven-development.md)
|
|
292
|
+
|
|
293
|
+
**Required Inputs**:
|
|
294
|
+
- Component or feature name
|
|
295
|
+
- High-level requirements
|
|
296
|
+
- Technical constraints
|
|
297
|
+
- Accessibility requirements
|
|
298
|
+
|
|
299
|
+
**Example**:
|
|
300
|
+
```
|
|
301
|
+
Create specification for ImageGallery component
|
|
302
|
+
Requirements: responsive grid, lazy loading, keyboard navigation
|
|
303
|
+
Constraints: < 500kb initial bundle, WCAG AA compliance
|
|
304
|
+
Output: ImageGallery.spec.md following SDD template
|
|
305
|
+
```
|
|
306
|
+
|
|
307
|
+
---
|
|
308
|
+
|
|
309
|
+
### 8. Storybook Documentation Agent
|
|
310
|
+
**Purpose**: Generate comprehensive Storybook stories and documentation
|
|
311
|
+
|
|
312
|
+
**Instruction**: [storybook.instructions.md](./instructions/storybook.instructions.md)
|
|
313
|
+
|
|
314
|
+
**Capabilities**:
|
|
315
|
+
- Creates interactive stories with all component variants
|
|
316
|
+
- Generates MDX documentation with usage examples
|
|
317
|
+
- Adds accessibility annotations
|
|
318
|
+
- Includes controls for interactive testing
|
|
319
|
+
- Creates demo/helper components for complex interactions
|
|
320
|
+
- Documents props, events, and customization options
|
|
321
|
+
|
|
322
|
+
**Required Inputs**:
|
|
323
|
+
- Component name or file path
|
|
324
|
+
- Story scenarios to demonstrate
|
|
325
|
+
- Documentation structure preferences
|
|
326
|
+
|
|
327
|
+
**Example**:
|
|
328
|
+
```
|
|
329
|
+
Create Storybook documentation for Alert component
|
|
330
|
+
Scenarios: all severity levels, dismissible variants, with/without actions
|
|
331
|
+
Include: accessibility section, code examples, interactive controls
|
|
332
|
+
```
|
|
333
|
+
|
|
334
|
+
---
|
|
335
|
+
|
|
336
|
+
## Agent Selection Guide
|
|
337
|
+
|
|
338
|
+
| Task | Recommended Agent | Alternative |
|
|
339
|
+
|------|------------------|-------------|
|
|
340
|
+
| Create new component | Component Scaffolding | Specification Development |
|
|
341
|
+
| Write documentation | Storybook Documentation | - |
|
|
342
|
+
| Fix accessibility | Accessibility Audit | Component Refactor |
|
|
343
|
+
| Improve performance | Performance Optimization | Component Refactor |
|
|
344
|
+
| Add AI features | AI Integration (Gemini) | - |
|
|
345
|
+
| Refactor existing code | Component Refactor | Performance Optimization |
|
|
346
|
+
| Generate PR description | Pull Request | - |
|
|
347
|
+
| Create spec before coding | Specification Development | Component Scaffolding |
|
|
348
|
+
| Optimize bundle size | Performance Optimization | - |
|
|
349
|
+
| Reduce re-renders | Performance Optimization | Component Refactor |
|
|
350
|
+
| Add keyboard navigation | Accessibility Audit | Component Refactor |
|
|
351
|
+
|
|
352
|
+
---
|
|
353
|
+
|
|
354
|
+
## Development Workflow
|
|
355
|
+
|
|
356
|
+
### Standard Component Creation Process
|
|
357
|
+
1. **Specification Development Agent** → Create `[ComponentName].spec.md`
|
|
358
|
+
2. **Component Scaffolding Agent** → Generate component files following spec
|
|
359
|
+
3. **Accessibility Audit Agent** → Verify WCAG compliance
|
|
360
|
+
4. **Storybook Documentation Agent** → Create interactive documentation
|
|
361
|
+
5. **Pull Request Agent** → Generate PR description
|
|
362
|
+
|
|
363
|
+
### Performance Optimization Process
|
|
364
|
+
1. **Performance Optimization Agent** → Identify bottlenecks and apply optimizations
|
|
365
|
+
2. **Component Refactor Agent** → Refactor based on recommendations
|
|
366
|
+
3. **Accessibility Audit Agent** → Ensure optimizations don't break accessibility
|
|
367
|
+
4. **Pull Request Agent** → Document performance improvements
|
|
368
|
+
|
|
369
|
+
### Refactoring Process
|
|
370
|
+
1. **Specification Development Agent** → Update/create component spec
|
|
371
|
+
2. **Component Refactor Agent** → Implement refactoring following spec
|
|
372
|
+
3. **Accessibility Audit Agent** → Verify accessibility maintained
|
|
373
|
+
4. **Performance Optimization Agent** → Optimize if needed
|
|
374
|
+
5. **Pull Request Agent** → Generate PR with migration notes
|
|
375
|
+
|
|
376
|
+
---
|
|
377
|
+
|
|
378
|
+
## Repository Structure Reference
|
|
379
|
+
|
|
380
|
+
### Core Files
|
|
381
|
+
| File | Purpose | Agent Usage |
|
|
382
|
+
|------|---------|-------------|
|
|
383
|
+
| `AGENTS.md` | Agent guidelines and workflows | All agents reference for project standards |
|
|
384
|
+
| `README.md` | Repository overview and navigation | Context for all agents |
|
|
385
|
+
|
|
386
|
+
### Instructions
|
|
387
|
+
| File | Purpose | Agent Usage |
|
|
388
|
+
|------|---------|-------------|
|
|
389
|
+
| `instructions/development-standards.instructions.md` | Code style and quality standards | Component Scaffolding, Component Refactor |
|
|
390
|
+
| `instructions/web-interface-guidelines.instructions.md` | Accessibility and UX guidelines | All agents building UI components |
|
|
391
|
+
| `instructions/mui.instructions.md` | Material-UI (MUI v7+) specific patterns and theming | Component Scaffolding (when MUI detected), Component Refactor |
|
|
392
|
+
| `instructions/storybook.instructions.md` | Documentation standards | Storybook Documentation |
|
|
393
|
+
| `instructions/github-issue.instructions.md` | Issue creation guidelines | Pull Request, Specification Development |
|
|
394
|
+
| `instructions/github-release-notes.instructions.md` | Release documentation standards | Pull Request |
|
|
395
|
+
|
|
396
|
+
### Rules
|
|
397
|
+
| File | Purpose | Agent Usage |
|
|
398
|
+
|------|---------|-------------|
|
|
399
|
+
| `rules/component-architecture.md` | Folder-per-component pattern | Component Scaffolding, Component Refactor |
|
|
400
|
+
| `rules/spec-driven-development.md` | Spec-first development process | All agents creating new features |
|
|
401
|
+
| `rules/accessibility.md` | WCAG compliance guidelines | Accessibility Audit, Component Scaffolding |
|
|
402
|
+
| `rules/web-performance.md` | Performance optimization patterns | Performance Optimization |
|
|
403
|
+
| `rules/react-19-compiler.md` | React 19 optimization guidelines | Performance Optimization, Component Refactor |
|
|
404
|
+
| `rules/gemini.md` | Google Gemini AI integration rules, security, and UX patterns | AI Integration (Gemini) |
|
|
405
|
+
| `rules/mui.md` | Material-UI architecture patterns and constraints | Component Scaffolding (when MUI detected), Component Refactor |
|
|
406
|
+
| `rules/tailwind-v4.md` | Tailwind CSS v4 patterns | Component Scaffolding (when Tailwind detected) |
|
|
407
|
+
| `rules/three-js-react.md` | 3D graphics integration | Component Scaffolding (when Three.js detected) |
|
|
408
|
+
| `rules/supabase.md` | Backend integration patterns | AI Integration, Component Scaffolding |
|
|
409
|
+
|
|
410
|
+
### Prompts
|
|
411
|
+
| File | Purpose | Agent Usage |
|
|
412
|
+
|------|---------|-------------|
|
|
413
|
+
| `prompts/scaffold-component.prompt.md` | Component creation template | Component Scaffolding |
|
|
414
|
+
| `prompts/create-pr.prompt.md` | PR description template | Pull Request |
|
|
415
|
+
|
|
416
|
+
### Skills
|
|
417
|
+
| Directory | Purpose | Agent Usage |
|
|
418
|
+
|-----------|---------|-------------|
|
|
419
|
+
| `skills/accessibility-audit/` | Accessibility verification checklist | Accessibility Audit |
|
|
420
|
+
| `skills/scaffold-component/` | Component scaffolding workflow | Component Scaffolding |
|
|
421
|
+
| `skills/integrate-gemini/` | AI integration patterns | AI Integration |
|
|
422
|
+
| `skills/vercel-react-best-practices/` | Performance optimization rules (45 rules, 8 categories) | Performance Optimization |
|
|
423
|
+
| `skills/workflows/` | Development workflows (SDD, setup) | All agents following SDD |
|
|
424
|
+
|
|
425
|
+
---
|
|
426
|
+
|
|
427
|
+
## Additional Resources
|
|
428
|
+
|
|
429
|
+
### Accessibility
|
|
430
|
+
- **WCAG Guidelines**: https://www.w3.org/WAI/WCAG22/quickref/
|
|
431
|
+
- **WAI-ARIA Authoring Practices**: https://www.w3.org/WAI/ARIA/apg/patterns/
|
|
432
|
+
- **APCA Contrast Calculator**: https://apcacontrast.com/
|
|
433
|
+
|
|
434
|
+
### React & TypeScript
|
|
435
|
+
- **React Documentation**: https://react.dev/
|
|
436
|
+
- **TypeScript Handbook**: https://www.typescriptlang.org/docs/
|
|
437
|
+
- **Vercel React Best Practices**: https://github.com/vercel/next.js/tree/canary/examples/with-react-best-practices
|
|
438
|
+
|
|
439
|
+
### Performance
|
|
440
|
+
- **Web.dev Performance**: https://web.dev/fast/
|
|
441
|
+
- **Core Web Vitals**: https://web.dev/vitals/
|
|
442
|
+
- **React DevTools Profiler**: https://react.dev/learn/react-developer-tools
|
|
443
|
+
|
|
444
|
+
### Testing & Documentation
|
|
445
|
+
- **Storybook Documentation**: https://storybook.js.org/docs/react/
|
|
446
|
+
- **Testing Library**: https://testing-library.com/docs/react-testing-library/intro/
|
|
447
|
+
- **Playwright**: https://playwright.dev/
|
|
448
|
+
|
|
449
|
+
### Standards & Patterns
|
|
450
|
+
- **MDN Web Docs**: https://developer.mozilla.org/
|
|
451
|
+
- **Can I Use**: https://caniuse.com/
|
|
452
|
+
- **Modern CSS Solutions**: https://moderncss.dev/
|
|
453
|
+
|
|
454
|
+
---
|
|
455
|
+
|
|
456
|
+
## Contributing to This Repository
|
|
457
|
+
|
|
458
|
+
To extend or modify this agents knowledge base:
|
|
459
|
+
|
|
460
|
+
### Adding New Rules
|
|
461
|
+
1. Create file in `rules/[topic-name].md`
|
|
462
|
+
2. Follow existing rule format (problem, solution, examples)
|
|
463
|
+
3. Reference from relevant agent in `AGENTS.md`
|
|
464
|
+
4. Update `README.md` with description
|
|
465
|
+
|
|
466
|
+
### Adding New Skills
|
|
467
|
+
1. Create directory `skills/[skill-name]/`
|
|
468
|
+
2. Add `SKILL.md` with frontmatter and documentation
|
|
469
|
+
3. Include examples and integration patterns
|
|
470
|
+
4. Reference from relevant agent in `AGENTS.md`
|
|
471
|
+
|
|
472
|
+
### Adding New Agents
|
|
473
|
+
1. Define clear **purpose** and **capabilities**
|
|
474
|
+
2. Specify required **inputs** and expected **outputs**
|
|
475
|
+
3. Provide concrete **examples** of usage
|
|
476
|
+
4. Add to **Agent Selection Guide** table
|
|
477
|
+
5. Update **Development Workflow** if applicable
|
|
478
|
+
6. Consider which **rules** and **skills** it should reference
|
|
479
|
+
|
|
480
|
+
### Updating Instructions
|
|
481
|
+
1. Edit files in `instructions/` directory
|
|
482
|
+
2. Keep guidelines concise and actionable
|
|
483
|
+
3. Use MUST/SHOULD/NEVER for clarity
|
|
484
|
+
4. Include examples where helpful
|
|
485
|
+
5. Update agent references if scope changes
|
|
486
|
+
|
|
487
|
+
---
|
|
488
|
+
|
|
489
|
+
**Last Updated**: January 31, 2026
|
|
490
|
+
|
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2025 Eric Thayer
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|