shadcn-ui

giuseppe-trisciuoglio/developer-kit · updated Apr 8, 2026

MDX-style export adds YAML metadata + attribution linking explainx.ai and this canonical listing URL.

$npx skills add https://github.com/giuseppe-trisciuoglio/developer-kit --skill shadcn-ui
0 commentsdiscussion
summary

Complete guide to building accessible React components with shadcn/ui, Radix UI, and Tailwind CSS.

  • Install and configure components via CLI ( npx shadcn@latest add ), then customize directly in your project since you own the code
  • Covers 10+ core components: buttons, inputs, forms with Zod validation, cards, dialogs, dropdowns, sheets, tables, toasts, and charts built on Recharts
  • Full Next.js App Router integration with Server Components, form handling, and metadata support; all compo
skill.md

shadcn/ui Component Patterns

Build accessible, customizable UI components with shadcn/ui, Radix UI, and Tailwind CSS.

Overview

  • Components are copied into your project — you own and customize the code
  • Built on Radix UI primitives for full accessibility
  • Styled with Tailwind CSS and CSS variables for theming
  • CLI-based installation: npx shadcn@latest add <component>

When to Use

Activate when user requests involve:

  • "Set up shadcn/ui", "initialize shadcn", "add shadcn components"
  • "Install button/input/form/dialog/card/select/toast/table/chart"
  • "React Hook Form", "Zod validation", "form with validation"
  • "accessible components", "Radix UI", "Tailwind theme"
  • "shadcn button", "shadcn dialog", "shadcn sheet", "shadcn table"
  • "dark mode", "CSS variables", "custom theme"
  • "charts with Recharts", "bar chart", "line chart", "pie chart"

Quick Reference

Available Components

Component Install Command Description
button npx shadcn@latest add button Variants: default, destructive, outline, secondary, ghost, link
input npx shadcn@latest add input Text input field
form npx shadcn@latest add form React Hook Form integration with validation
card npx shadcn@latest add card Container with header, content, footer
dialog npx shadcn@latest add dialog Modal overlay
sheet npx shadcn@latest add sheet Slide-over panel (top/right/bottom/left)
select npx shadcn@latest add select Dropdown select
toast npx shadcn@latest add toast Notification toasts
table npx shadcn@latest add table Data table
menubar npx shadcn@latest add menubar Desktop-style menubar
chart npx shadcn@latest add chart Recharts wrapper with theming
textarea npx shadcn@latest add textarea Multi-line text input
checkbox npx shadcn@latest add checkbox Checkbox input
label npx shadcn@latest add label Accessible form label

Instructions

Initialize Project

# New Next.js project
npx create-next-app@latest my-app --typescript --tailwind --eslint --app
cd my-app
npx shadcn@latest init

# Existing project
npm install tailwindcss-animate class-variance-authority clsx tailwind-merge lucide-react
npx shadcn@latest init

# Install components
npx shadcn@latest add button input form card dialog select toast

Basic Component Usage

// Button with variants and sizes
import { Button } from "@/components/ui/button"

<Button variant="default">Default</Button>
<Button variant="destructive" size="sm">Delete</Button>
<Button variant="outline" disabled>Loading...</Button>

Form with Zod Validation

"use client"

import { zodResolver } from "@hookform/resolvers/zod"
import { useForm } from "react-hook-form"
import { z } from "zod"
import { Button } from "@/components/ui/button"
import { Form, FormControl, FormField, FormItem, FormLabel, FormMessage } from "@/components/ui/form"
import { Input } from "@/components/ui/input"

const formSchema = z.object({
  email: z.string().email("Invalid email"),
  password: z.string().min(8, "Password must be at least 8 characters"),
})

export function LoginForm() {
  const form = useForm<z.infer<typeof formSchema>>({
    resolver: zodResolver(formSchema),
    defaultValues: { email: "", password: "" },
  })

  return (
    <Form {...form}>
      <form onSubmit={form.handleSubmit(console.log)} className="space-y-4">
        <FormField name="email" control={form.control} render={({ field }) => (
          <FormItem>
            <FormLabel>Email</FormLabel>
            <FormControl><Input type="email" {...field} /></FormControl>
            <FormMessage />
          </FormItem>
        )} />
        <FormField name="password" control={form.control} render={({ field }) => (
          <FormItem>
            <FormLabel>Password</FormLabel>
            <FormControl><Input type="password" {...field} /></FormControl>
            <FormMessage />
          </FormItem>
        )} />
        <Button type="submit">Login</Button>
      </form>
    
how to use shadcn-ui

How to use shadcn-ui on Cursor

AI-first code editor with Composer

1

Prerequisites

Before installing skills in Cursor, ensure your development environment meets these requirements:

  • Cursor installed and configured on your development machine
  • Node.js version 16.0+ with npm package manager (verify with node --version)
  • Active project directory or workspace where you want to add shadcn-ui
2

Execute installation command

Execute the skills CLI command in your project's root directory to begin installation:

$npx skills add https://github.com/giuseppe-trisciuoglio/developer-kit --skill shadcn-ui

The skills CLI fetches shadcn-ui from GitHub repository giuseppe-trisciuoglio/developer-kit and configures it for Cursor.

3

Select Cursor when prompted

The CLI will show a list of available agents. Use arrow keys to navigate and space to select Cursor:

◆ Which agents do you want to install to?
│ ── Universal (.agents/skills) ── always included ────
│ • Amp
│ • Antigravity
│ • Cline
│ • Codex
│ ●Cursor(selected)
│ • Cursor
│ • Windsurf
4

Verify installation

Confirm successful installation by checking the skill directory location:

.cursor/skills/shadcn-ui

Reload or restart Cursor to activate shadcn-ui. Access the skill through slash commands (e.g., /shadcn-ui) or your agent's skill management interface.

Security & Verification Notice

We perform automated surface-level scans (Gen AI Scanner, Socket, Snyk) during installation. These checks detect common vulnerabilities but do not guarantee complete security. Always review skill source code and verify the publisher's reputation before production use.

Skills execute code in your development environment. Always verify the publisher's identity, review recent commits, and test in isolated environments before production deployment.

List & Monetize Your Skill

Submit your Claude Code skill and start earning

GET_STARTED →

Use Cases

Task Automation & Efficiency

Automate repetitive workflows and reduce manual effort

Example

Generate reports, summarize documents, draft communications

Save 3-5 hours per week on routine tasks

Knowledge Enhancement

Learn new skills, understand complex topics, get expert guidance

Example

Explain concepts, provide examples, suggest learning resources

Accelerate learning and skill development by 2x

Quality Improvement

Enhance output quality through reviews, suggestions, and refinements

Example

Review drafts, suggest improvements, catch errors

Improve work quality by 30-40% with less effort

Implementation Guide

Prerequisites

  • Claude Desktop or compatible AI client with skill support
  • Clear understanding of task or problem to solve
  • Willingness to iterate and refine outputs

Time Estimate

15-45 minutes depending on use case complexity

Installation Steps

  1. 1.Install skill using provided installation command
  2. 2.Test with simple use case relevant to your work
  3. 3.Evaluate output quality and relevance
  4. 4.Iterate on prompts to improve results
  5. 5.Integrate into regular workflow if valuable

Common Pitfalls

  • Expecting perfect results without iteration
  • Not providing enough context in prompts
  • Using skill for tasks outside its intended scope
  • Accepting outputs without review and validation

Best Practices

✓ Do

  • +Start with clear, specific prompts
  • +Provide relevant context and constraints
  • +Review and refine all outputs before using
  • +Iterate to improve output quality
  • +Document successful prompt patterns

✗ Don't

  • Don't use without understanding skill limitations
  • Don't skip validation of outputs
  • Don't share sensitive information in prompts
  • Don't expect skill to replace human judgment

💡 Pro Tips

  • Be specific about desired format and style
  • Ask for multiple options to choose from
  • Request explanations to understand reasoning
  • Combine AI efficiency with human expertise

When to Use This

✓ Use When

Use when skill capabilities match your task, clear ROI on time saved, and you can validate outputs. Best for repetitive tasks, learning, and quality improvement.

✗ Avoid When

Avoid when task requires deep expertise you can't validate, involves sensitive decisions, or when learning process is more valuable than speed of completion.

Learning Path

  1. 1Familiarize yourself with skill capabilities and limitations
  2. 2Start with low-risk, non-critical tasks
  3. 3Progress to more complex and valuable use cases
  4. 4Build expertise through regular use and experimentation

Discussion

Product Hunt–style comments (not star reviews)
  • No comments yet — start the thread.
general reviews

Ratings

4.730 reviews
  • Ganesh Mohane· Dec 28, 2024

    We added shadcn-ui from the explainx registry; install was straightforward and the SKILL.md answered most questions upfront.

  • Omar Desai· Dec 8, 2024

    Useful defaults in shadcn-ui — fewer surprises than typical one-off scripts, and it plays nicely with `npx skills` flows.

  • Shikha Mishra· Dec 4, 2024

    I recommend shadcn-ui for anyone iterating fast on agent tooling; clear intent and a small, reviewable surface area.

  • Aarav Haddad· Nov 27, 2024

    I recommend shadcn-ui for anyone iterating fast on agent tooling; clear intent and a small, reviewable surface area.

  • Valentina Mehta· Nov 27, 2024

    Solid pick for teams standardizing on skills: shadcn-ui is focused, and the summary matches what you get after install.

  • Yash Thakker· Nov 23, 2024

    Useful defaults in shadcn-ui — fewer surprises than typical one-off scripts, and it plays nicely with `npx skills` flows.

  • Isabella Liu· Oct 18, 2024

    shadcn-ui reduced setup friction for our internal harness; good balance of opinion and flexibility.

  • William Kim· Oct 18, 2024

    We added shadcn-ui from the explainx registry; install was straightforward and the SKILL.md answered most questions upfront.

  • Dhruvi Jain· Oct 14, 2024

    shadcn-ui has been reliable in day-to-day use. Documentation quality is above average for community skills.

  • Isabella Taylor· Sep 25, 2024

    Registry listing for shadcn-ui matched our evaluation — installs cleanly and behaves as described in the markdown.

showing 1-10 of 30

1 / 3