shadcn

SKILL.md

shadcn/ui Community Best Practices

Comprehensive best practices guide for shadcn/ui applications, maintained by the shadcn/ui community. Contains 42 rules across 8 categories, prioritized by impact to guide automated refactoring and code generation.

When to Apply

Reference these guidelines when:

  • Writing new shadcn/ui components or composing primitives
  • Implementing forms with React Hook Form and Zod validation
  • Building data tables or handling large dataset displays
  • Customizing themes or adding dark mode support
  • Reviewing code for accessibility compliance

Rule Categories by Priority

Priority Category Impact Prefix
1 Component Architecture CRITICAL arch-
2 Accessibility Preservation CRITICAL ally-
3 Styling & Theming HIGH style-
4 Form Patterns HIGH form-
5 Data Display MEDIUM-HIGH data-
6 Component Composition MEDIUM comp-
7 Performance Optimization MEDIUM perf-
8 State Management LOW-MEDIUM state-

Quick Reference

1. Component Architecture (CRITICAL)

2. Accessibility Preservation (CRITICAL)

3. Styling & Theming (HIGH)

4. Form Patterns (HIGH)

5. Data Display (MEDIUM-HIGH)

6. Component Composition (MEDIUM)

7. Performance Optimization (MEDIUM)

8. State Management (LOW-MEDIUM)

How to Use

Read individual reference files for detailed explanations and code examples:

Full Compiled Document

For a single-file reference containing all rules, see AGENTS.md.

Reference Files

File Description
AGENTS.md Complete compiled guide with all rules
references/_sections.md Category definitions and ordering
assets/templates/_template.md Template for new rules
metadata.json Version and reference information
Weekly Installs
7
First Seen
Jan 27, 2026
Installed on
gemini-cli7
github-copilot7
claude-code6
codex5
kimi-cli5
cursor5