@jgamaraalv/ts-dev-kit 3.3.0 → 5.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/.claude-plugin/marketplace.json +1 -1
- package/.claude-plugin/plugin.json +1 -1
- package/CHANGELOG.md +33 -0
- package/agent-memory/nextjs-expert/MEMORY.md +3 -0
- package/agents/multi-agent-coordinator.md +147 -0
- package/agents/nextjs-expert.md +91 -0
- package/package.json +1 -1
- package/skills/bullmq/SKILL.md +30 -10
- package/skills/codebase-adapter/SKILL.md +2 -2
- package/skills/composition-patterns/SKILL.md +12 -0
- package/skills/core-web-vitals/SKILL.md +47 -31
- package/skills/docker/SKILL.md +18 -6
- package/skills/drizzle-pg/SKILL.md +21 -9
- package/skills/execute-task/SKILL.md +13 -3
- package/skills/execute-task/references/agent-dispatch.md +43 -0
- package/skills/fastify-best-practices/SKILL.md +16 -4
- package/skills/generate-prd/SKILL.md +2 -2
- package/skills/ioredis/SKILL.md +21 -9
- package/skills/nextjs-best-practices/SKILL.md +3 -21
- package/skills/owasp-security-review/SKILL.md +31 -13
- package/skills/postgresql/SKILL.md +22 -10
- package/skills/react-best-practices/SKILL.md +7 -12
- package/skills/service-worker/SKILL.md +50 -39
- package/skills/tanstack-query/SKILL.md +16 -0
- package/skills/typescript-conventions/SKILL.md +8 -0
- package/skills/ui-ux-guidelines/SKILL.md +24 -16
- package/skills/yolo/SKILL.md +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,39 @@ All notable changes to this project will be documented in this file.
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
|
6
6
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
+
## [5.0.0] - 2026-02-28
|
|
9
|
+
|
|
10
|
+
### Changed
|
|
11
|
+
|
|
12
|
+
- Standardize all 15 reference and workflow skills to use semantic XML tags (`<rules>`, `<quick_reference>`, `<examples>`, `<anti_patterns>`, `<gotchas>`, `<constraints>`, `<references>`, `<workflow>`, `<output>`) — previously only 7 workflow skills used XML tags while 15 reference skills used plain markdown headings
|
|
13
|
+
- Skills with multi-step workflows (`owasp-security-review`, `ui-ux-guidelines`) now use `<workflow>` with numbered `<phase_N_name>` tags matching the pattern established by `debug`, `execute-task`, and `generate-prd`
|
|
14
|
+
|
|
15
|
+
### BREAKING CHANGE
|
|
16
|
+
|
|
17
|
+
- All skill SKILL.md files now wrap content sections in XML tags. Custom forks or overrides that parse skill files by markdown heading structure may need updating to account for the new XML tag wrappers.
|
|
18
|
+
|
|
19
|
+
## [4.0.0] - 2026-02-27
|
|
20
|
+
|
|
21
|
+
### Added
|
|
22
|
+
|
|
23
|
+
- Publish `multi-agent-coordinator` agent to the npm package — previously only available locally in `.claude/agents/`, now shipped in `agents/` with all other agents
|
|
24
|
+
- Publish `nextjs-expert` agent to the npm package — rewritten as repository-agnostic (no hardcoded paths, commands, or project-specific conventions); discovers project structure dynamically
|
|
25
|
+
- Add `agent-memory/nextjs-expert/` persistent memory directory
|
|
26
|
+
- Add worktree isolation support to `/execute-task` dispatch protocol: new decision tree in `rule_3_execution_order`, new dispatch step for `isolation: "worktree"` on parallel agents with overlapping files, new anti-pattern #5 ("never dispatch parallel agents on overlapping files without worktree isolation"), new self-check item
|
|
27
|
+
- Add worktree isolation dispatch example to `/execute-task` agent-dispatch reference with concrete `isolation: "worktree"` Task() calls and guidance on when NOT to use isolation
|
|
28
|
+
- Add `isolation` field to `multi-agent-coordinator` dispatch plan output format — parallel tasks that touch overlapping files now include `isolation: worktree`
|
|
29
|
+
- Add worktree isolation rule to `multi-agent-coordinator` planning guidelines
|
|
30
|
+
|
|
31
|
+
### Changed
|
|
32
|
+
|
|
33
|
+
- Agent count in published `agents/` directory: 13 → 15 (now matches the "15 agents" stated in all manifests)
|
|
34
|
+
- Agent memory count: 13 → 14 directories (added nextjs-expert; multi-agent-coordinator excluded as planner-only)
|
|
35
|
+
- CLAUDE.md content layout updated to reflect correct agent-memory count (14) and exclusion list (only multi-agent-coordinator)
|
|
36
|
+
|
|
37
|
+
### BREAKING CHANGE
|
|
38
|
+
|
|
39
|
+
- All 15 agents are now published in the npm package. Projects that relied on the previous 13-agent subset and have custom agent overrides for `multi-agent-coordinator` or `nextjs-expert` may experience conflicts with the newly published versions.
|
|
40
|
+
|
|
8
41
|
## [3.3.0] - 2026-02-27
|
|
9
42
|
|
|
10
43
|
### Added
|
|
@@ -0,0 +1,147 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: multi-agent-coordinator
|
|
3
|
+
description: "Multi-agent orchestration planner that analyzes complex tasks and returns structured dispatch plans. It does NOT implement code or dispatch agents itself — it returns a plan that the caller executes. Use for large features spanning multiple packages."
|
|
4
|
+
color: yellow
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
You are a multi-agent orchestration **planner**. You analyze complex tasks, read the codebase, and produce a **structured dispatch plan** that the caller will execute.
|
|
8
|
+
|
|
9
|
+
## CRITICAL CONSTRAINT: YOU ARE A PLANNER, NOT AN IMPLEMENTER
|
|
10
|
+
|
|
11
|
+
You **cannot** dispatch subagents (no Task tool). You **cannot** write or edit files (no Write/Edit tools). You **cannot** run commands (no Bash tool).
|
|
12
|
+
|
|
13
|
+
Your ONLY job is to:
|
|
14
|
+
|
|
15
|
+
1. **Read** the spec and relevant codebase files to understand the work
|
|
16
|
+
2. **Analyze** dependencies and determine execution order
|
|
17
|
+
3. **Return** a structured dispatch plan in the exact format below
|
|
18
|
+
|
|
19
|
+
The **caller** (main Claude Code session) will read your plan and dispatch the specialized subagents.
|
|
20
|
+
|
|
21
|
+
<project_context>
|
|
22
|
+
Discover the project structure before producing any plan:
|
|
23
|
+
|
|
24
|
+
1. Read the project's CLAUDE.md (if it exists) for architecture, conventions, and commands.
|
|
25
|
+
2. Read `package.json` (root and workspaces), check for monorepo config (`pnpm-workspace.yaml`, `turbo.json`, `lerna.json`, etc.).
|
|
26
|
+
3. Identify the dependency graph — determine the build order between packages/apps.
|
|
27
|
+
4. Detect conventions: read existing source files, linter configs, tsconfig, and formatter configs.
|
|
28
|
+
5. Check for orchestration rules: look for `.claude/rules/orchestration.md` or similar guidance files.
|
|
29
|
+
</project_context>
|
|
30
|
+
|
|
31
|
+
## Output Format
|
|
32
|
+
|
|
33
|
+
You MUST return your plan in this exact structure. The caller parses this to dispatch agents.
|
|
34
|
+
|
|
35
|
+
```markdown
|
|
36
|
+
## Dispatch Plan
|
|
37
|
+
|
|
38
|
+
### Phase 1: <Phase Name>
|
|
39
|
+
|
|
40
|
+
> Dependencies: none
|
|
41
|
+
> Parallel: yes/no
|
|
42
|
+
|
|
43
|
+
#### Task 1.1: <Short Title>
|
|
44
|
+
|
|
45
|
+
- **subagent_type**: <agent type from available list>
|
|
46
|
+
- **model**: <haiku|sonnet|opus or "inherit">
|
|
47
|
+
- **isolation**: <worktree or omit> _(set to `worktree` when this task runs in parallel with others that touch overlapping files)_
|
|
48
|
+
- **description**: <3-5 word summary for Task tool>
|
|
49
|
+
- **prompt**: |
|
|
50
|
+
<Full detailed prompt for the subagent. Include:
|
|
51
|
+
- What files to create/modify (exact paths)
|
|
52
|
+
- What code to write (specifications, not actual code)
|
|
53
|
+
- What conventions to follow
|
|
54
|
+
- What commands to run for verification
|
|
55
|
+
- Any context from previous phases>
|
|
56
|
+
|
|
57
|
+
#### Task 1.2: <Short Title>
|
|
58
|
+
|
|
59
|
+
...
|
|
60
|
+
|
|
61
|
+
### Phase 2: <Phase Name>
|
|
62
|
+
|
|
63
|
+
> Dependencies: Phase 1
|
|
64
|
+
> Parallel: yes/no
|
|
65
|
+
|
|
66
|
+
#### Task 2.1: <Short Title>
|
|
67
|
+
|
|
68
|
+
...
|
|
69
|
+
|
|
70
|
+
### Phase N: Quality Gates
|
|
71
|
+
|
|
72
|
+
> Dependencies: all previous phases
|
|
73
|
+
> Parallel: no
|
|
74
|
+
|
|
75
|
+
#### Task N.1: Verify integration
|
|
76
|
+
|
|
77
|
+
- **subagent_type**: Bash
|
|
78
|
+
- **description**: <summary>
|
|
79
|
+
- **prompt**: |
|
|
80
|
+
Run quality gates (adapt commands to the project's package manager and workspace structure):
|
|
81
|
+
- Type-check all packages/apps
|
|
82
|
+
- Run linter
|
|
83
|
+
- Run full build
|
|
84
|
+
```
|
|
85
|
+
|
|
86
|
+
## Available Subagent Types
|
|
87
|
+
|
|
88
|
+
**MANDATORY RULE: Always prefer specialized agents over `general-purpose`.** Only use `general-purpose` when NO specialized agent matches the task domain. If a task spans multiple domains (e.g., schema changes + API routes), choose the agent that matches the **primary** work. If truly mixed, split into smaller tasks assigned to different specialized agents.
|
|
89
|
+
|
|
90
|
+
| subagent_type | Use for | Can edit files? |
|
|
91
|
+
| -------------------- | ---------------------------------------------------- | --------------- |
|
|
92
|
+
| typescript-pro | Shared types, generics, type safety, Zod schemas | Yes |
|
|
93
|
+
| api-builder | Fastify routes, plugins, hooks, use cases, API logic | Yes |
|
|
94
|
+
| database-expert | DB schema, migrations, queries, Drizzle ORM | Yes |
|
|
95
|
+
| nextjs-expert | Next.js pages, layouts, data fetching, CSP, config | Yes |
|
|
96
|
+
| react-specialist | React components, hooks, state, forms | Yes |
|
|
97
|
+
| test-generator | Unit, integration, E2E tests | Yes |
|
|
98
|
+
| security-scanner | Auth, validation, vulnerability scan | Yes |
|
|
99
|
+
| accessibility-pro | WCAG compliance, screen readers | Yes |
|
|
100
|
+
| performance-engineer | Caching, query optimization, bundles | Yes |
|
|
101
|
+
| general-purpose | ONLY when no specialized agent fits the task | Yes |
|
|
102
|
+
| Bash | Git ops, command execution, verification | No |
|
|
103
|
+
| Explore | Codebase research, file discovery | No |
|
|
104
|
+
|
|
105
|
+
### Agent Selection Examples
|
|
106
|
+
|
|
107
|
+
- Shared Zod schemas + TypeScript types → `typescript-pro`
|
|
108
|
+
- Drizzle schema columns + migrations → `database-expert`
|
|
109
|
+
- Fastify adapters, use cases, route handlers, plugins → `api-builder`
|
|
110
|
+
- Next.js pages + config changes → `nextjs-expert`
|
|
111
|
+
- React form components, OTP input, client state → `react-specialist`
|
|
112
|
+
- Installing deps + running quality gates (no code logic) → `general-purpose` or `Bash`
|
|
113
|
+
|
|
114
|
+
## Planning Guidelines
|
|
115
|
+
|
|
116
|
+
### Plan Construction Rules
|
|
117
|
+
|
|
118
|
+
- Respect the project's dependency graph (shared/core packages build before consuming apps)
|
|
119
|
+
- **Maximize parallelism: independent tasks in the same phase MUST be marked `Parallel: yes` and the caller MUST dispatch them as multiple Task() calls in a single message.** Do not sequentialize independent work.
|
|
120
|
+
- **Use worktree isolation for parallel tasks with overlapping files**: when two or more tasks in a `Parallel: yes` phase modify any of the same files (shared barrel exports, config files, common modules), add `isolation: worktree` to each task. This gives each agent an isolated copy of the repository, preventing edit conflicts. Omit `isolation` when tasks touch completely separate files.
|
|
121
|
+
- Each task prompt must be self-contained (the subagent has no context from other tasks)
|
|
122
|
+
- Include verification commands in each task prompt (use the project's actual workspace commands)
|
|
123
|
+
- **Include Context7 lookup instructions** in every task prompt that involves config or versioned APIs: agents must query `mcp__context7__resolve-library-id` + `mcp__context7__query-docs` before writing config files
|
|
124
|
+
- Final phase should always be quality gates
|
|
125
|
+
- **Quality gate fix protocol**: the quality gates phase prompt must instruct the caller to dispatch a specialist agent (not fix inline) when gates fail. Include: "If any gate fails, dispatch a specialist agent (e.g., typescript-pro for type errors, debugger for investigation) to fix the errors. Do NOT fix errors inline in the orchestrator session."
|
|
126
|
+
|
|
127
|
+
### Effective task prompts include:
|
|
128
|
+
|
|
129
|
+
1. **Context**: What feature/task this is part of
|
|
130
|
+
2. **Scope**: Exact files to create/modify with full paths
|
|
131
|
+
3. **Spec**: Detailed specifications (paste relevant sections from the spec doc)
|
|
132
|
+
4. **Conventions**: Project-specific coding conventions discovered during codebase analysis
|
|
133
|
+
5. **Dependencies**: What files/types were created by previous phases
|
|
134
|
+
6. **Verification**: Commands to run after implementation (using the project's actual tooling)
|
|
135
|
+
|
|
136
|
+
## Conventions Discovery
|
|
137
|
+
|
|
138
|
+
Instead of hardcoding conventions, **always discover them from the codebase**. When writing subagent prompts, include the relevant conventions you found. Common things to check:
|
|
139
|
+
|
|
140
|
+
- **Package manager**: npm, yarn, pnpm, bun (check lockfile and scripts)
|
|
141
|
+
- **Module system**: CJS vs ESM (check `"type"` in package.json, tsconfig `module`)
|
|
142
|
+
- **Import style**: Check for `consistent-type-imports`, path aliases, extension conventions
|
|
143
|
+
- **Formatting**: Check Prettier/ESLint/Biome configs for quotes, semicolons, line width, etc.
|
|
144
|
+
- **Framework patterns**: Check existing routes, components, and plugins for established patterns
|
|
145
|
+
- **ORM/DB**: Check which ORM and driver are used (Drizzle, Prisma, etc.)
|
|
146
|
+
- **Testing**: Check test framework and file naming conventions
|
|
147
|
+
- **UI library**: Check for component library usage (shadcn, MUI, etc.) and CSS approach
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: nextjs-expert
|
|
3
|
+
description: "Next.js expert specializing in App Router, React Server Components, edge functions, and full-stack patterns. Use when building pages, implementing data fetching, configuring routing, optimizing SEO, or working with server actions."
|
|
4
|
+
color: white
|
|
5
|
+
memory: project
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
You are a Next.js expert specializing in the App Router, React Server Components (RSC), and modern full-stack patterns working on the current project.
|
|
9
|
+
|
|
10
|
+
<project_context>
|
|
11
|
+
Discover the project structure before starting:
|
|
12
|
+
|
|
13
|
+
1. Read the project's CLAUDE.md (if it exists) for architecture, conventions, and commands.
|
|
14
|
+
2. Check package.json for the package manager, scripts, and dependencies.
|
|
15
|
+
3. Explore the directory structure to understand the codebase layout.
|
|
16
|
+
4. Find the Next.js app directory (e.g., `app/` or `src/app/`) and inspect its file conventions.
|
|
17
|
+
5. Identify the React and Next.js versions from package.json.
|
|
18
|
+
6. Check for UI libraries (shadcn/ui, MUI, etc.), CSS approach (Tailwind, CSS Modules), and path aliases.
|
|
19
|
+
7. Follow the conventions found in the codebase — check existing pages, layouts, imports, and CLAUDE.md.
|
|
20
|
+
</project_context>
|
|
21
|
+
|
|
22
|
+
<workflow>
|
|
23
|
+
1. Understand the requirement (page, component, data flow, feature).
|
|
24
|
+
2. Check the existing app directory structure and routing conventions.
|
|
25
|
+
3. Determine server vs. client boundary placement.
|
|
26
|
+
4. Implement following App Router conventions from the preloaded nextjs-best-practices skill.
|
|
27
|
+
5. Run quality gates.
|
|
28
|
+
</workflow>
|
|
29
|
+
|
|
30
|
+
<library_docs>
|
|
31
|
+
When you need to verify API signatures or check version-specific behavior, use Context7:
|
|
32
|
+
|
|
33
|
+
1. `mcp__context7__resolve-library-id` — resolve the library name to its ID.
|
|
34
|
+
2. `mcp__context7__query-docs` — query the specific API or pattern.
|
|
35
|
+
</library_docs>
|
|
36
|
+
|
|
37
|
+
<principles>
|
|
38
|
+
- Server Components by default — only add `"use client"` when you need browser APIs or interactivity.
|
|
39
|
+
- Minimize client JavaScript — ship less code, load faster.
|
|
40
|
+
- Co-locate data fetching with the component that needs it.
|
|
41
|
+
- Use the file system conventions — layouts, loading, error boundaries.
|
|
42
|
+
- Type everything — leverage TypeScript for route params, search params, metadata.
|
|
43
|
+
- Progressive enhancement — the app should work before JS loads.
|
|
44
|
+
</principles>
|
|
45
|
+
|
|
46
|
+
<server_client_boundary>
|
|
47
|
+
Key decisions for server vs. client:
|
|
48
|
+
|
|
49
|
+
- **Maps, geolocation, browser APIs**: Always client — need browser APIs.
|
|
50
|
+
- **Search/filter forms, interactive UI**: Client — need useState/useEffect.
|
|
51
|
+
- **Data display (cards, lists, stats, tables)**: Server — just display data.
|
|
52
|
+
- **Photo galleries**: Client if interactive (swipe, zoom), Server if static.
|
|
53
|
+
|
|
54
|
+
```
|
|
55
|
+
Server Component (page.tsx)
|
|
56
|
+
├── Server Component (DataCard) — static display
|
|
57
|
+
├── Client Component (SearchForm) — interactive form
|
|
58
|
+
│ └── Client Component (MapPicker) — browser API
|
|
59
|
+
└── Server Component (Stats) — data display
|
|
60
|
+
```
|
|
61
|
+
</server_client_boundary>
|
|
62
|
+
|
|
63
|
+
<quality_gates>
|
|
64
|
+
Run the project's standard quality checks for every package you touched. Discover the available commands from package.json scripts. Fix failures before reporting done:
|
|
65
|
+
|
|
66
|
+
- Type checking (e.g., `tsc` or equivalent)
|
|
67
|
+
- Linting (e.g., `lint` script)
|
|
68
|
+
- Build (e.g., `build` script)
|
|
69
|
+
</quality_gates>
|
|
70
|
+
|
|
71
|
+
<output>
|
|
72
|
+
Report when done:
|
|
73
|
+
- Summary: one sentence of what was built.
|
|
74
|
+
- Files: each file created/modified.
|
|
75
|
+
- Quality gates: pass/fail for each.
|
|
76
|
+
</output>
|
|
77
|
+
|
|
78
|
+
<agent-memory>
|
|
79
|
+
You have a persistent memory directory. Its contents persist across conversations. To find it, look for `agent-memory/nextjs-expert/` at the project root first, then fall back to `.claude/agent-memory/nextjs-expert/`. Use whichever path exists.
|
|
80
|
+
|
|
81
|
+
As you work, consult your memory files to build on previous experience. When you encounter a mistake that seems like it could be common, check your agent memory for relevant notes — and if nothing is written yet, record what you learned.
|
|
82
|
+
|
|
83
|
+
Guidelines:
|
|
84
|
+
|
|
85
|
+
- Record insights about problem constraints, strategies that worked or failed, and lessons learned
|
|
86
|
+
- Update or remove memories that turn out to be wrong or outdated
|
|
87
|
+
- Organize memory semantically by topic, not chronologically
|
|
88
|
+
- `MEMORY.md` is always loaded into your system prompt — lines after 200 will be truncated, so keep it concise and link to other files in your agent memory directory for details
|
|
89
|
+
- Use the Write and Edit tools to update your memory files
|
|
90
|
+
- Since this memory is project-scope and shared with your team via version control, tailor your memories to this project
|
|
91
|
+
</agent-memory>
|
package/package.json
CHANGED
package/skills/bullmq/SKILL.md
CHANGED
|
@@ -23,6 +23,8 @@ Redis-backed queue system for Node.js. Four core classes: `Queue`, `Worker`, `Qu
|
|
|
23
23
|
|
|
24
24
|
`yarn add bullmq` — requires Redis 5.0+ with `maxmemory-policy=noeviction`.
|
|
25
25
|
|
|
26
|
+
<quick_reference>
|
|
27
|
+
|
|
26
28
|
## Quick Start
|
|
27
29
|
|
|
28
30
|
```ts
|
|
@@ -73,6 +75,22 @@ queueEvents.on("failed", ({ jobId, failedReason }) => {
|
|
|
73
75
|
});
|
|
74
76
|
```
|
|
75
77
|
|
|
78
|
+
## Job Lifecycle States
|
|
79
|
+
|
|
80
|
+
```
|
|
81
|
+
add() → wait / prioritized / delayed
|
|
82
|
+
↓
|
|
83
|
+
active → completed
|
|
84
|
+
↓
|
|
85
|
+
failed → (retry) → wait/delayed
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
With FlowProducer: jobs can also be in `waiting-children` state until all children complete.
|
|
89
|
+
|
|
90
|
+
</quick_reference>
|
|
91
|
+
|
|
92
|
+
<rules>
|
|
93
|
+
|
|
76
94
|
## Connections
|
|
77
95
|
|
|
78
96
|
BullMQ uses ioredis internally. Pass `connection` options or an existing ioredis instance.
|
|
@@ -103,6 +121,10 @@ const w1 = new Worker("q1", async (job) => {}, { connection: workerConn });
|
|
|
103
121
|
- `QueueEvents` cannot share connections (uses blocking Redis commands).
|
|
104
122
|
- Redis MUST have `maxmemory-policy=noeviction`.
|
|
105
123
|
|
|
124
|
+
</rules>
|
|
125
|
+
|
|
126
|
+
<examples>
|
|
127
|
+
|
|
106
128
|
## Queue
|
|
107
129
|
|
|
108
130
|
```ts
|
|
@@ -179,6 +201,10 @@ const worker = new Worker<JobData, JobReturn>("paint", async (job) => {
|
|
|
179
201
|
});
|
|
180
202
|
```
|
|
181
203
|
|
|
204
|
+
</examples>
|
|
205
|
+
|
|
206
|
+
<events>
|
|
207
|
+
|
|
182
208
|
## Events
|
|
183
209
|
|
|
184
210
|
**Worker events** (local to that worker instance):
|
|
@@ -205,17 +231,9 @@ const worker = new Worker<JobData, JobReturn>("paint", async (job) => {
|
|
|
205
231
|
|
|
206
232
|
Event stream is auto-trimmed (~10,000 events). Configure via `streams.events.maxLen`.
|
|
207
233
|
|
|
208
|
-
|
|
234
|
+
</events>
|
|
209
235
|
|
|
210
|
-
|
|
211
|
-
add() → wait / prioritized / delayed
|
|
212
|
-
↓
|
|
213
|
-
active → completed
|
|
214
|
-
↓
|
|
215
|
-
failed → (retry) → wait/delayed
|
|
216
|
-
```
|
|
217
|
-
|
|
218
|
-
With FlowProducer: jobs can also be in `waiting-children` state until all children complete.
|
|
236
|
+
<references>
|
|
219
237
|
|
|
220
238
|
## Advanced Topics
|
|
221
239
|
|
|
@@ -223,3 +241,5 @@ With FlowProducer: jobs can also be in `waiting-children` state until all childr
|
|
|
223
241
|
- **Flows and schedulers** (FlowProducer, parent-child, job schedulers, cron): See [references/flows-and-schedulers.md](references/flows-and-schedulers.md)
|
|
224
242
|
- **Patterns** (step jobs, idempotent, throttle, manual rate-limit): See [references/patterns.md](references/patterns.md)
|
|
225
243
|
- **Production** (shutdown, Redis config, retries, backoff, monitoring): See [references/production.md](references/production.md)
|
|
244
|
+
|
|
245
|
+
</references>
|
|
@@ -6,9 +6,9 @@ argument-hint: "[optional: path to project root — defaults to current director
|
|
|
6
6
|
allowed-tools: Bash(ls *), Bash(cat *), Bash(node *), Bash(python3 *)
|
|
7
7
|
---
|
|
8
8
|
|
|
9
|
-
<
|
|
9
|
+
<role>
|
|
10
10
|
You are a plugin configuration specialist. You adapt specific, well-defined sections in ts-dev-kit's skill and agent files to match the host project — making them accurate and immediately useful without touching any workflow, phase logic, or behavioral patterns.
|
|
11
|
-
</
|
|
11
|
+
</role>
|
|
12
12
|
|
|
13
13
|
<context>
|
|
14
14
|
**User-provided path:** $ARGUMENTS
|
|
@@ -10,6 +10,8 @@ boolean prop proliferation by using compound components, lifting state, and
|
|
|
10
10
|
composing internals. These patterns make codebases easier for both humans and AI
|
|
11
11
|
agents to work with as they scale.
|
|
12
12
|
|
|
13
|
+
<constraints>
|
|
14
|
+
|
|
13
15
|
## When NOT to Use
|
|
14
16
|
|
|
15
17
|
Skip these patterns when: fewer than 3 props, simple variants, or single-use components.
|
|
@@ -24,6 +26,10 @@ Reference these guidelines when:
|
|
|
24
26
|
- Reviewing component architecture
|
|
25
27
|
- Working with compound components or context providers
|
|
26
28
|
|
|
29
|
+
</constraints>
|
|
30
|
+
|
|
31
|
+
<rules>
|
|
32
|
+
|
|
27
33
|
## Rule Categories by Priority
|
|
28
34
|
|
|
29
35
|
| Priority | Category | Impact | Prefix |
|
|
@@ -33,6 +39,10 @@ Reference these guidelines when:
|
|
|
33
39
|
| 3 | Implementation Patterns | MEDIUM | `patterns-` |
|
|
34
40
|
| 4 | React 19 APIs | MEDIUM | `react19-` |
|
|
35
41
|
|
|
42
|
+
</rules>
|
|
43
|
+
|
|
44
|
+
<references>
|
|
45
|
+
|
|
36
46
|
## Quick Reference
|
|
37
47
|
|
|
38
48
|
### 1. Component Architecture (HIGH)
|
|
@@ -56,3 +66,5 @@ Reference these guidelines when:
|
|
|
56
66
|
> **React 19+ only.** Skip this section if using React 18 or earlier.
|
|
57
67
|
|
|
58
68
|
- **No forwardRef** — Don't use `forwardRef`; pass `ref` as a regular prop. Use `use()` instead of `useContext()` — see [references/react19-no-forwardref.md](references/react19-no-forwardref.md)
|
|
69
|
+
|
|
70
|
+
</references>
|
|
@@ -9,6 +9,8 @@ allowed-tools: Bash(python3 *)
|
|
|
9
9
|
The three stable Core Web Vitals, each measured at the **75th percentile** of
|
|
10
10
|
real page loads (segmented by mobile and desktop):
|
|
11
11
|
|
|
12
|
+
<quick_reference>
|
|
13
|
+
|
|
12
14
|
| Metric | Measures | Good | Needs Improvement | Poor |
|
|
13
15
|
|--------|----------|------|-------------------|------|
|
|
14
16
|
| **LCP** — Largest Contentful Paint | Loading | ≤ 2.5 s | 2.5–4.0 s | > 4.0 s |
|
|
@@ -17,6 +19,36 @@ real page loads (segmented by mobile and desktop):
|
|
|
17
19
|
|
|
18
20
|
A page **passes** Core Web Vitals only if all three metrics meet "Good" at the 75th percentile.
|
|
19
21
|
|
|
22
|
+
## Supporting metrics (non-Core but diagnostic)
|
|
23
|
+
|
|
24
|
+
- **FCP** (First Contentful Paint) — diagnoses render-blocking resources upstream of LCP
|
|
25
|
+
- **TTFB** (Time to First Byte) — server response time; directly affects LCP
|
|
26
|
+
- **TBT** (Total Blocking Time) — lab proxy for INP; identifies long tasks
|
|
27
|
+
|
|
28
|
+
## Tools matrix
|
|
29
|
+
|
|
30
|
+
| Tool | Type | LCP | INP | CLS | Notes |
|
|
31
|
+
|------|------|-----|-----|-----|-------|
|
|
32
|
+
| Chrome User Experience Report (CrUX) | Field | ✓ | ✓ | ✓ | 28-day rolling window of real users |
|
|
33
|
+
| PageSpeed Insights | Field + Lab | ✓ | ✓ | ✓ | Field = CrUX data; Lab = Lighthouse |
|
|
34
|
+
| Search Console CWV report | Field | ✓ | ✓ | ✓ | Groups URLs by template |
|
|
35
|
+
| Chrome DevTools Performance panel | Field + Lab | ✓ | ✓ | ✓ | Local profiling, interaction tracing |
|
|
36
|
+
| Lighthouse | Lab | ✓ | TBT* | ✓ | CI integration; INP → use TBT as proxy |
|
|
37
|
+
|
|
38
|
+
*Lighthouse uses **Total Blocking Time (TBT)** as a lab proxy for INP. TBT
|
|
39
|
+
correlates with INP but does not replace field measurement.
|
|
40
|
+
|
|
41
|
+
## Metric lifecycle
|
|
42
|
+
|
|
43
|
+
Metrics progress through: **Experimental → Pending → Stable**.
|
|
44
|
+
All three current Core Web Vitals (LCP, CLS, INP) are **Stable**.
|
|
45
|
+
INP replaced FID (First Input Delay) in March 2024.
|
|
46
|
+
Changes to stable metrics follow an annual cadence with advance notice.
|
|
47
|
+
|
|
48
|
+
</quick_reference>
|
|
49
|
+
|
|
50
|
+
<examples>
|
|
51
|
+
|
|
20
52
|
## Quick setup: measure all three in the field
|
|
21
53
|
|
|
22
54
|
```bash
|
|
@@ -43,33 +75,9 @@ Each callback receives `{ name, value, rating, delta, id, navigationType }`.
|
|
|
43
75
|
> The `web-vitals` library handles bfcache restores, prerendered pages, iframe
|
|
44
76
|
> aggregation, and other edge cases that raw PerformanceObserver does not.
|
|
45
77
|
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
| Tool | Type | LCP | INP | CLS | Notes |
|
|
49
|
-
|------|------|-----|-----|-----|-------|
|
|
50
|
-
| Chrome User Experience Report (CrUX) | Field | ✓ | ✓ | ✓ | 28-day rolling window of real users |
|
|
51
|
-
| PageSpeed Insights | Field + Lab | ✓ | ✓ | ✓ | Field = CrUX data; Lab = Lighthouse |
|
|
52
|
-
| Search Console CWV report | Field | ✓ | ✓ | ✓ | Groups URLs by template |
|
|
53
|
-
| Chrome DevTools Performance panel | Field + Lab | ✓ | ✓ | ✓ | Local profiling, interaction tracing |
|
|
54
|
-
| Lighthouse | Lab | ✓ | TBT* | ✓ | CI integration; INP → use TBT as proxy |
|
|
55
|
-
|
|
56
|
-
*Lighthouse uses **Total Blocking Time (TBT)** as a lab proxy for INP. TBT
|
|
57
|
-
correlates with INP but does not replace field measurement.
|
|
58
|
-
|
|
59
|
-
## Supporting metrics (non-Core but diagnostic)
|
|
60
|
-
|
|
61
|
-
- **FCP** (First Contentful Paint) — diagnoses render-blocking resources upstream of LCP
|
|
62
|
-
- **TTFB** (Time to First Byte) — server response time; directly affects LCP
|
|
63
|
-
- **TBT** (Total Blocking Time) — lab proxy for INP; identifies long tasks
|
|
78
|
+
</examples>
|
|
64
79
|
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
| Reference | Read when… |
|
|
68
|
-
|-----------|-----------|
|
|
69
|
-
| [references/lcp.md](references/lcp.md) | LCP > 2.5 s, diagnosing slow image/text load, preload/CDN questions |
|
|
70
|
-
| [references/inp.md](references/inp.md) | INP > 200 ms, slow click/key/tap response, long task investigations |
|
|
71
|
-
| [references/cls.md](references/cls.md) | CLS > 0.1, elements jumping on scroll or load, font/image shift |
|
|
72
|
-
| [references/tools.md](references/tools.md) | Setting up monitoring, using DevTools/Lighthouse/PSI, top-9 optimization checklist |
|
|
80
|
+
<visual_report>
|
|
73
81
|
|
|
74
82
|
## Generate a visual report
|
|
75
83
|
|
|
@@ -101,9 +109,17 @@ python3 SCRIPT_PATH/visualize.py \
|
|
|
101
109
|
The script (`scripts/visualize.py`) requires only Python 3 stdlib — no packages to install.
|
|
102
110
|
It outputs a self-contained HTML file with color-coded metric cards, a visual progress bar showing where each value falls on the Good/Needs Improvement/Poor scale, and an overall PASS/FAIL/NEEDS IMPROVEMENT verdict.
|
|
103
111
|
|
|
104
|
-
|
|
112
|
+
</visual_report>
|
|
105
113
|
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
114
|
+
<references>
|
|
115
|
+
|
|
116
|
+
## When to read reference files
|
|
117
|
+
|
|
118
|
+
| Reference | Read when… |
|
|
119
|
+
|-----------|-----------|
|
|
120
|
+
| [references/lcp.md](references/lcp.md) | LCP > 2.5 s, diagnosing slow image/text load, preload/CDN questions |
|
|
121
|
+
| [references/inp.md](references/inp.md) | INP > 200 ms, slow click/key/tap response, long task investigations |
|
|
122
|
+
| [references/cls.md](references/cls.md) | CLS > 0.1, elements jumping on scroll or load, font/image shift |
|
|
123
|
+
| [references/tools.md](references/tools.md) | Setting up monitoring, using DevTools/Lighthouse/PSI, top-9 optimization checklist |
|
|
124
|
+
|
|
125
|
+
</references>
|
package/skills/docker/SKILL.md
CHANGED
|
@@ -8,12 +8,7 @@ description: "Docker containerization reference — multi-stage builds, Compose
|
|
|
8
8
|
|
|
9
9
|
Docker best practices for Node.js monorepos with Yarn 4 Berry.
|
|
10
10
|
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
| Need | Reference file |
|
|
14
|
-
| -------------------------------------------------- | ---------------------------------------------------------------------- |
|
|
15
|
-
| Writing or reviewing a Dockerfile for the monorepo | [references/monorepo-dockerfile.md](references/monorepo-dockerfile.md) |
|
|
16
|
-
| Configuring docker-compose for dev or production | [references/compose-configs.md](references/compose-configs.md) |
|
|
11
|
+
<rules>
|
|
17
12
|
|
|
18
13
|
## Key Principles
|
|
19
14
|
|
|
@@ -41,6 +36,10 @@ Docker best practices for Node.js monorepos with Yarn 4 Berry.
|
|
|
41
36
|
- Read-only filesystem where possible: `read_only: true`
|
|
42
37
|
- Drop capabilities: `cap_drop: [ALL]`
|
|
43
38
|
|
|
39
|
+
</rules>
|
|
40
|
+
|
|
41
|
+
<quick_reference>
|
|
42
|
+
|
|
44
43
|
## Useful Commands
|
|
45
44
|
|
|
46
45
|
```bash
|
|
@@ -53,3 +52,16 @@ docker system df # View cache usage
|
|
|
53
52
|
docker system prune -a # Prune unused images
|
|
54
53
|
docker stats # Resource usage
|
|
55
54
|
```
|
|
55
|
+
|
|
56
|
+
</quick_reference>
|
|
57
|
+
|
|
58
|
+
<references>
|
|
59
|
+
|
|
60
|
+
## When to Load References
|
|
61
|
+
|
|
62
|
+
| Need | Reference file |
|
|
63
|
+
| -------------------------------------------------- | ---------------------------------------------------------------------- |
|
|
64
|
+
| Writing or reviewing a Dockerfile for the monorepo | [references/monorepo-dockerfile.md](references/monorepo-dockerfile.md) |
|
|
65
|
+
| Configuring docker-compose for dev or production | [references/compose-configs.md](references/compose-configs.md) |
|
|
66
|
+
|
|
67
|
+
</references>
|
|
@@ -15,6 +15,8 @@ Packages: `drizzle-orm` (runtime), `drizzle-kit` (CLI/migrations).
|
|
|
15
15
|
- [Common Patterns](#common-patterns)
|
|
16
16
|
- [Reference Files](#reference-files)
|
|
17
17
|
|
|
18
|
+
<examples>
|
|
19
|
+
|
|
18
20
|
## Quick Start
|
|
19
21
|
|
|
20
22
|
### Connect
|
|
@@ -151,15 +153,6 @@ npx drizzle-kit pull # introspect DB -> Drizzle schema
|
|
|
151
153
|
npx drizzle-kit studio # visual browser UI
|
|
152
154
|
```
|
|
153
155
|
|
|
154
|
-
## Import Cheat Sheet
|
|
155
|
-
|
|
156
|
-
| Import path | Key exports |
|
|
157
|
-
| --------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
158
|
-
| `drizzle-orm/pg-core` | `pgTable`, `pgEnum`, column types (`serial`, `text`, `integer`, `uuid`, `timestamp`, `jsonb`, `varchar`, `boolean`, `numeric`, `bigint`, `geometry`, `vector`, ...), `index`, `uniqueIndex`, `unique`, `check`, `primaryKey`, `foreignKey` |
|
|
159
|
-
| `drizzle-orm` | Operators: `eq`, `ne`, `gt`, `gte`, `lt`, `lte`, `and`, `or`, `not`, `isNull`, `isNotNull`, `inArray`, `between`, `like`, `ilike`, `exists`, `sql`, `asc`, `desc`. Utilities: `getColumns`, `defineRelations`, `cosineDistance`, `l2Distance` |
|
|
160
|
-
| `drizzle-orm` (types) | `InferSelectModel`, `InferInsertModel` |
|
|
161
|
-
| `drizzle-zod` | `createInsertSchema`, `createSelectSchema` |
|
|
162
|
-
|
|
163
156
|
## Common Patterns
|
|
164
157
|
|
|
165
158
|
### Conditional filters
|
|
@@ -190,6 +183,23 @@ type User = typeof users.$inferSelect;
|
|
|
190
183
|
type NewUser = typeof users.$inferInsert;
|
|
191
184
|
```
|
|
192
185
|
|
|
186
|
+
</examples>
|
|
187
|
+
|
|
188
|
+
<quick_reference>
|
|
189
|
+
|
|
190
|
+
## Import Cheat Sheet
|
|
191
|
+
|
|
192
|
+
| Import path | Key exports |
|
|
193
|
+
| --------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
194
|
+
| `drizzle-orm/pg-core` | `pgTable`, `pgEnum`, column types (`serial`, `text`, `integer`, `uuid`, `timestamp`, `jsonb`, `varchar`, `boolean`, `numeric`, `bigint`, `geometry`, `vector`, ...), `index`, `uniqueIndex`, `unique`, `check`, `primaryKey`, `foreignKey` |
|
|
195
|
+
| `drizzle-orm` | Operators: `eq`, `ne`, `gt`, `gte`, `lt`, `lte`, `and`, `or`, `not`, `isNull`, `isNotNull`, `inArray`, `between`, `like`, `ilike`, `exists`, `sql`, `asc`, `desc`. Utilities: `getColumns`, `defineRelations`, `cosineDistance`, `l2Distance` |
|
|
196
|
+
| `drizzle-orm` (types) | `InferSelectModel`, `InferInsertModel` |
|
|
197
|
+
| `drizzle-zod` | `createInsertSchema`, `createSelectSchema` |
|
|
198
|
+
|
|
199
|
+
</quick_reference>
|
|
200
|
+
|
|
201
|
+
<references>
|
|
202
|
+
|
|
193
203
|
## Reference Files
|
|
194
204
|
|
|
195
205
|
For detailed API coverage, see:
|
|
@@ -200,3 +210,5 @@ For detailed API coverage, see:
|
|
|
200
210
|
- **sql`` template: raw, empty, join, identifier, placeholders**: [references/sql-operator.md](references/sql-operator.md)
|
|
201
211
|
- **drizzle-kit commands, drizzle.config.ts, migration workflows**: [references/migrations.md](references/migrations.md)
|
|
202
212
|
- **Dynamic queries, transactions, custom types, Zod, utilities**: [references/advanced.md](references/advanced.md)
|
|
213
|
+
|
|
214
|
+
</references>
|