Back to Skills

react:components

Converts Stitch designs into modular Vite and React components using system-level networking and AST-based validation.

507stars32forksUpdated 1/24/2026

Security Assessment

Safe(100/100)
Security Score100/100

About react:components

The 'react:components' skill is designed to transform Stitch designs into modular React components, specifically tailored for Vite-based projects. By automating the conversion of designs into clean, reusable code, it streamlines the frontend development process. This skill integrates with system-level networking and leverages AST-based validation to ensure that the generated components adhere to strict architectural standards, ensuring consistency, reliability, and scalability in the codebase.

The main features of this skill include the modular breakdown of design elements into individual React components, isolating business logic into custom hooks, and managing data decoupling through mock data files. It emphasizes type safety with TypeScript and maintains design fidelity by mapping Tailwind CSS configurations to the generated code. The execution flow guides the user through setting up the environment, drafting components, applying them to the project, and performing quality checks. Additionally, troubleshooting steps are provided to handle common errors such as fetch and validation issues, ensuring a smooth development process.

This skill is particularly useful for frontend developers and engineers working with Vite and React who need to convert designs into functional, modular components. It is ideal for teams looking to automate design-to-code workflows and maintain high-quality standards in their frontend architecture. Whether used for small-scale projects or larger, more complex applications, 'react:components' simplifies the process of building maintainable and scalable React applications.

FAQ

How do I fetch a design for processing with 'react:components'?

You can fetch a design by running the '[prefix]:get_screen' command to retrieve the design JSON. Make sure to replace '[prefix]' with the appropriate Stitch MCP prefix (e.g., 'stitch:').

What tools are required to use 'react:components'?

The skill requires access to the 'stitch', 'Bash', 'Read', 'Write', and 'web_fetch' tools for various tasks, including fetching designs and running scripts.

Are there any compatibility restrictions for using 'react:components'?

This skill is designed to work with Vite and React projects, and the generated components should be compatible with those frameworks. Ensure that the required dependencies like 'node_modules' are installed and up-to-date.

What happens if a fetch command fails while retrieving a design?

If a fetch fails, you can manually run a Bash script (`bash scripts/fetch-stitch.sh`) to handle redirects and security handshakes to ensure a reliable download.

Is there any guidance on verifying the final component output?

Yes, after drafting the components, you should run 'npm run validate <file_path>' to check for errors. Additionally, verify the output against the 'resources/architecture-checklist.md' and start the dev server with 'npm run dev' to ensure everything renders correctly.

All Files

4 files
package-lock.json7.0 KB
View
package.json0.3 KB
View
README.md1.3 KB
View
SKILL.md2.7 KB
View

Install react:components

Download and extract the skill files to your .claude/skills/ directory.

Quick Setup:

  1. Copy the skill folder to .claude/skills/
  2. Claude will automatically detect and use the skill