nextjs-performance
Read docs/agent/architecture/nextjs-critical-fixes.md for full patterns; Check existing components in apps/frontend/components/
Works with
Agent Skills format with YAML frontmatter. Claude Code reads it as-is.
---
name: "nextjs-performance"
description: "Read docs/agent/architecture/nextjs-critical-fixes.md for full patterns; Check existing components in apps/frontend/components/"
license: "Apache-2.0"
---
# Next.js Performance
## Before Writing Code
1. Read `docs/agent/architecture/nextjs-critical-fixes.md` for full patterns
2. Check existing components in `apps/frontend/components/`
## Critical Rules
### Waterfalls
- Use `Promise.all()` for independent fetches
- Wrap slow data in `<Suspense>` boundaries
- Defer `await` into branches where needed
```tsx
// WRONG
const resumes = await fetchResumes();
const jobs = await fetchJobs();
// RIGHT
const [resumes, jobs] = await Promise.all([fetchResumes(), fetchJobs()]);
```
### Bundle Size
- **NO barrel imports**: `import X from 'lucide-react'` is WRONG
- **YES direct imports**: `import X from 'lucide-react/dist/esm/icons/x'`
- Use `next/dynamic` for heavy components (editors, charts, PDF)
- Defer analytics with `ssr: false`
```tsx
import dynamic from 'next/dynamic';
const HeavyEditor = dynamic(() => import('./HeavyEditor'), { ssr: false });
```
### Server Actions
- **ALWAYS** check auth INSIDE the action, not just middleware
- Verify resource ownership before mutations
### Production Build
- Run `npm run build && npm run start`, NOT `npm run dev`
- Docker must use standalone output
## Pre-PR Checklist
```
[ ] No sequential awaits for independent data
[ ] Icons imported directly (not barrel)
[ ] Heavy components use next/dynamic
[ ] Server Actions have auth inside
[ ] Suspense around slow fetches
```More Frontend Frameworks skills
frontend-design
anthropics/skills
Guidance for distinctive, intentional visual design when building new UI or reshaping an existing one. Helps with aesthetic direction, typography, and making choices that don't read as templated defaults.
design-taste-frontend
leonxlnx/taste-skill
Anti-slop frontend skill for landing pages, portfolios, and redesigns. The agent reads the brief, infers the right design direction, and ships interfaces that do not look templated. Real design systems when applicable, audit-first on redesigns, strict pre-flight check.
hyperframes-creative
heygen-com/hyperframes
Non-animation creative direction for HyperFrames videos. Use for design spec (frame.md / design.md) handling, palettes, typography, narration, beat planning, audio-reactive visuals, composition patterns, and brand / style decisions. For atomic motion patterns and scene blueprints, use hyperframes-animation.

