mcpField
S
shadcn

shadcn

github.com/pproencaDesign & UI220729 installsUpdated 11w ago
Repository

About shadcn

A community-maintained best-practices guide for developers building with shadcn/ui. Its prioritized rules cover setup, component composition, accessibility, forms, styling, and data display.

Key features

  1. 0158 prioritized rules across ten categories
  2. 02Project setup and component architecture advice
  3. 03Accessibility, styling, and theming guidance
  4. 04Form and data display patterns

Use cases

  1. 01Configuring shadcn/ui in a project
  2. 02Building accessible components and forms
  3. 03Customizing themes and dark mode
  4. 04Displaying tables and large datasets

Install

Copy the command and run it in a terminal.

$npx skills add https://github.com/pproenca/dot-skills --skill shadcn

After installing, type/shadcnin Claude Code to confirm it loaded.

Bundled files

References and scripts installed along with SKILL.md.

AGENTS.md
metadata.json
README.md
assets/templates/
_template.md
references/
_sections.md
ally-aria-invalid-errors.md
ally-checkbox-label-association.md
ally-dialog-title-required.md
ally-ensure-color-contrast.md
ally-focus-visible-styles.md
ally-form-field-labels.md
ally-maintain-focus-management.md
ally-preserve-aria-attributes.md
ally-preserve-keyboard-navigation.md
ally-provide-sr-only-labels.md
arch-extend-variants-with-cva.md
arch-forward-refs-for-composable-components.md
arch-isolate-component-variants.md
arch-preserve-radix-primitive-structure.md
arch-use-asChild-for-custom-triggers.md
arch-use-cn-for-class-merging.md
comp-combine-command-with-popover.md
comp-compose-with-compound-components.md
comp-create-reusable-form-fields.md
comp-nest-dialogs-correctly.md
comp-use-drawer-for-mobile-modals.md
comp-use-slot-pattern-for-flexibility.md
data-empty-states-with-guidance.md
data-paginate-server-side.md
data-use-skeleton-loading-states.md

Details

From the project README

shadcn/ui Community Best Practices

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

When to Apply

Reference these guidelines when:

  • Installing and configuring shadcn/ui in a project
  • 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

PriorityCategoryImpactPrefix
1CLI & Project SetupCRITICALsetup-
2Component ArchitectureCRITICALarch-
3Accessibility PreservationCRITICALally-
4Styling & ThemingHIGHstyle-
5Form PatternsHIGHform-
6Data DisplayMEDIUM-HIGHdata-
7Layout & NavigationMEDIUMlayout-
8Component CompositionMEDIUMcomp-
9Performance OptimizationMEDIUMperf-
10State ManagementLOW-MEDIUMstate-

Quick Reference

1. CLI & Project Setup (CRITICAL)
2. Component Architecture (CRITICAL)
3. Accessibility Preservation (CRITICAL)
4. Styling & Theming (HIGH)
5. Form Patterns (HIGH)
6. Data Display (MEDIUM-HIGH)
7. Layout & Navigation (MEDIUM)
8. Component Composition (MEDIUM)
9. Performance Optimization (MEDIUM)
10. 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

FileDescription
AGENTS.mdComplete compiled guide with all rules
references/_sections.mdCategory definitions and ordering
assets/templates/_template.mdTemplate for new rules
metadata.jsonVersion and reference information

Comments

Markdown supported