agent-health
Reads production/traces/agent-metrics.jsonl and displays a per-agent performance summary table for the current or a specified…
Next.js App Router specific patterns — Server Components, Client Components boundary, parallel fetching, bundle analysis, a11y. Use ONLY for Next.js 13+ App Router projects. For generic React/Vue patterns, use `frontend-patterns` instead.
Claude Code
$ npx -y skills add tranhieutt/software_development_department --skill senior-frontend --agent claude-code
Codex
$ npx skills add tranhieutt/software_development_department --skill senior-frontend -a codex -y
Cursor
$ npx skills add tranhieutt/software_development_department --skill senior-frontend -a cursor -y
Gemini CLI
$ npx skills add tranhieutt/software_development_department --skill senior-frontend -a gemini-cli -y
GitHub Copilot
$ npx skills add tranhieutt/software_development_department --skill senior-frontend -a github-copilot -y
OpenCode
$ npx skills add tranhieutt/software_development_department --skill senior-frontend -a opencode -y
Windsurf
$ npx skills add tranhieutt/software_development_department --skill senior-frontend -a windsurf -y
name: senior-frontend type: reference description: "Next.js App Router specific patterns — Server Components, Client Components boundary, parallel fetching, bundle analysis, a11y. Use ONLY for Next.js 13+ App Router projects. For generic React/Vue patterns, use `frontend-patterns` instead." paths: ["**/app/**/*.tsx", "**/app/**/*.jsx", "**/next.config.*", "**/app/layout.tsx"] when_to_use: "When building Next.js 13+ App Router applications with Server Components, NOT for generic React/Vue (see `frontend-patterns`)" allowed-tools: Read, Glob, Grep, Write, Edit, Bash user-invocable: true effort: 3
// Server Component (default) — fetch directly, no hooks
async function ProductPage({ params }: { params: { id: string } }) {
const [product, reviews] = await Promise.all([ // parallel fetch
getProduct(params.id),
getReviews(params.id),
]);
return (
<div>
<h1>{product.name}</h1>
<Suspense fallback={<ReviewsSkeleton />}>
<Reviews productId={params.id} /> {/* can defer slow queries */}
</Suspense>
<AddToCartButton productId={product.id} /> {/* client boundary at leaf */}
</div>
);
}
// Client Component — only where interactivity needed
"use client";
function AddToCartButton({ productId }: { productId: string }) {
const [adding, setAdding] = useState(false);
return <button onClick={() => addToCart(productId)}>Add to Cart</button>;
}// next.config.js
const nextConfig = {
images: {
remotePatterns: [{ hostname: "cdn.example.com" }],
formats: ["image/avif", "image/webp"],
},
experimental: {
optimizePackageImports: ["lucide-react", "@heroicons/react"], // tree-shake icon libs
},
};// Generic list component
function List<T extends { id: string }>({ items, renderItem }: {
items: T[];
renderItem: (item: T) => React.ReactNode;
}) {
return <ul>{items.map(item => <li key={item.id}>{renderItem(item)}</li>)}</ul>;
}
// Props extending HTML element
interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement> {
variant?: "primary" | "ghost" | "danger";
isLoading?: boolean;
}
export function Button({ variant = "primary", isLoading, children, ...props }: ButtonProps) {
return (
<button {...props} disabled={props.disabled || isLoading} aria-busy={isLoading}
className={cn("px-4 py-2 rounded font-medium focus-visible:ring-2",
variant === "primary" && "bg-blue-600 text-white hover:bg-blue-700",
variant === "danger" && "bg-red-600 text-white",
(props.disabled || isLoading) && "opacity-50 cursor-not-allowed"
)}>
{isLoading && <Spinner aria-hidden />}
{children}
</button>
);
}Common heavy deps to replace:
| Package | Size | Alternative | |---|---|---| | moment | 290KB | `dayjs` (2KB) or `date-fns` (12KB) | | lodash | 71KB | `lodash-es` (tree-shakeable) | | axios | 14KB | native `fetch` or `ky` (3KB) | | @mui/material | Large | shadcn/ui or Radix UI |
# Analyze bundle npx @next/bundle-analyzer # or npx vite-bundle-visualizer
// Skip link — place before main nav <a href="#main-content" className="sr-only focus:not-sr-only focus:absolute focus:top-4 focus:left-4"> Skip to main content </a> // Icon button — always label <button type="button" aria-label="Close dialog" className="focus-visible:ring-2"> <XIcon aria-hidden="true" /> </button> // Minimum contrast: 4.5:1 for text, 3:1 for UI components
app/
├── layout.tsx # Root layout: fonts, providers, metadata
├── page.tsx
├── (auth)/ # Route group — no URL segment
│ ├── login/page.tsx
│ └── register/page.tsx
└── api/
└── [route]/route.ts
components/
├── ui/ # Button, Input, Card (reusable primitives)
└── features/ # Domain-specific composites
hooks/ # useDebounce, useLocalStorage, useMediaQuery
lib/
├── utils.ts # cn(), formatDate()
└── api.ts # API client
types/ # Shared TypeScript typesReads production/traces/agent-metrics.jsonl and displays a per-agent performance summary table for the current or a specified…
Provides the vendored agent-style v0.3.5 prose rule pack as a portable Claude skill. Use when installing, syncing, applying, or…
Provides Angular best practices for components, modules, services, and reactive patterns. Use when working with Angular…
Records unexpected API behaviors, undocumented caveats, version bugs, or non-obvious workarounds into…
Defines REST and GraphQL API contracts including endpoints, request/response schemas, auth flows, and versioning strategy. Use…
Manages the ADR (Architecture Decision Record) registry. Use when recording tech-stack choices, design patterns, or…
You MUST use this before any creative work - creating features, building components, adding functionality, modifying behavior, or…
Ask which skill or flow fits your situation. A router over the skills in this repo.