savinofiore/doe-kit/doe-frontend-standards
Claude Code and agent skill by savinofiore/doe-kit
- community
- ext:[{"type":"hook","description":"Pre/post lifecycle hooks"}]
Checking that the SKILL.md file is still in the repository.
React/Next.js frontend standards — component composition, compound components, custom hooks, Context+Reducer state, memoization, code splitting, list virtualization, forms, error boundaries, Framer Motion animation and accessible keyboard/focus patterns. Use when writing, reviewing or refactoring React or Next.js components, hooks or client-side state.
Install
npx vskill@latest install savinofiore/doe-kit/doe-frontend-standardsSemi-extensibleMentions customization, but needs skill-specific knowledge. Read the extensible skills standard
SKILL.md
The same SKILL.md was published earlier as savinofiore/doe-kit/doe-frontend-standards.
Pi: invoke this skill with/skill:doe-frontend-standards.
Frontend Standards — React / Next.js
Client-side conventions the generated code must satisfy. UI/UX rules (accessibility, touch targets, contrast, animation timing) live in the ui-standards skill.
Business logic does not live here: it lives in the framework-free core layer the DOE gate measures. Components and hooks are the thin layer on top. See .doe/README.md.
Component Patterns
Composition over inheritance. Build small parts, assemble at the call site.
Compound components when children need shared state — expose it via context, throw if used outside the provider.
Render props when the consumer must control rendering of async state (data / loading / error).
Custom Hooks
Extract reusable logic. One concern per hook.
Common set: useToggle, useDebounce, useQuery. Reach for TanStack Query before writing your own fetch/cache hook — library-first.
State Management
| Scope | Use | |
|---|---|---|
| Component-level | useState | |
| Complex shared state | Context + Reducer | |
| Global app state | Zustand / Redux — don't reinvent |
Performance
Code splitting — lazy load heavy components behind Suspense with a real skeleton fallback.
Virtualize long lists (@tanstack/react-virtual) — never render thousands of rows.
⚠️ Note: .sort() mutates. Spread before sorting inside useMemo or you mutate props.
Forms
- Validate on submit, show errors near the offending field
- Disable the submit button during async operations
- Keep
formDataanderrorsas separate state - In React artifacts: never use
<form>tags — wireonClick/onChangedirectly
Error Boundaries
Wrap route-level boundaries at minimum. Report to Sentry, not console.error.
Animation (Framer Motion)
Stable key per item or exit animations break. Timing rules → ui-standards.
Accessibility in Components
Keyboard navigation — handle ArrowUp / ArrowDown / Enter / Escape on any custom dropdown, listbox or menu. preventDefault() on arrows so the page doesn't scroll.
Focus management — on modal open, save document.activeElement, focus the modal, restore focus on close. Set role="dialog" + aria-modal="true" + tabIndex={-1}.
Code Review
Comment format
Checklist
- [ ] Edge cases + error states handled (empty, loading, error)
- [ ] No unnecessary re-renders · [ ] Bundle size impact considered
- [ ] Clear naming, no magic numbers · [ ] DRY, SOLID
- [ ] TypeScript types — never
any
Security
- Security scanPassed, 100 of 100Pattern checks on the skill's files.
- Model reviewNot runA model review is scheduled for the next rescan.
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingpi/skills/doe-frontend-standards/SKILL.md
Popularity
- Repository stars
- 2
- 7-day trend score
- 0
Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.
Extension points
hookPre/post lifecycle hooks
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/savinofiore/doe-kit/doe-frontend-standards)