component-builder

Creates reusable React components following shadcn/ui patterns with TypeScript and Tailwind CSS.

Updated Jul 28, 2026
One-click install
npx skills add https://github.com/human-centric-engineering/resparkable --skill component-builder-human-centric-engineering
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: component-builder
Source: https://github.com/human-centric-engineering/resparkable/tree/main/.claude/skills/component-builder
Command: npx skills add https://github.com/human-centric-engineering/resparkable --skill component-builder-human-centric-engineering

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Building consistent, accessible React components from scratch is slow and error-prone. This Skill standardizes component creation in a Next.js project by enforcing shadcn/ui patterns, TypeScript interfaces, Tailwind CSS styling, and accessibility attributes, so every new component matches the existing codebase conventions. ## Core Features & Use Cases - Guided 4-step workflow: Check for existing shadcn/ui primitives before writing new code, design a typed props interface, create the component, then add accessibility attributes. - Capsule-based placement rules: Routes components into the correct domain directory (ui/, forms/, marketing/, admin/, dashboard/, etc.) based on reuse scope. - Ready-made templates: Includes production patterns for marketing heroes, feature grids, and pricing tables using Card, Button, and lucide-react icons. - Use Case: Ask for a pricing section with three tiers, and get a components/marketing/pricing.tsx Server Component with typed plan props, responsive grid, and a highlighted popular plan. ## Quick Start Ask the assistant to create a hero section for the landing page with a title, subtitle, and two call-to-action buttons.

Frequently Asked Questions about component-builder

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create a new React component with shadcn/ui?▼

First check whether shadcn/ui already provides the component using npx shadcn@latest add [component-name]. If it exists, install or extend it rather than reimplementing. Otherwise define a TypeScript props interface, build the component with Tailwind classes, and add accessibility attributes.

When should a React component use 'use client' in Next.js?▼

Use Server Components by default and add 'use client' only when the component needs interactivity such as useState, event handlers, or browser APIs. A static feature card stays a Server Component, while a counter with buttons requires the client directive.

Where should I place a new component in a Next.js project?▼

Place reusable primitives shared across domains in components/ui/, form-specific components in forms/, and domain-bound components in their capsule such as admin/, dashboard/, or marketing/. App-wide shells like error boundaries live at the component root.

What accessibility attributes do React components need?▼

Buttons need type and aria-label, decorative icons need aria-hidden, meaningful icons need role="img" with aria-label, and form fields need aria-describedby and aria-invalid linked to error messages with role="alert". Images require descriptive alt text.

How do I add conditional Tailwind classes in React?▼

Use the cn() utility imported from @/lib/utils to merge base classes with conditional or consumer-provided className props. This keeps components customizable while preserving default styling like rounded-lg border bg-card.