Suite of tools for creating elaborate, multi-component claude.ai HTML artifacts using modern frontend web technologies (React, Tailwind CSS, shadcn/ui). Use for complex artifacts requiring state management, routing, or shadcn/ui components - not for simple single-file HTML/JSX artifacts.
Add this skill
npx mdskills install anthropics/web-artifacts-builderProvides clear workflow for building React artifacts with shadcn/ui and bundling to single HTML files
1---2name: web-artifacts-builder3description: Suite of tools for creating elaborate, multi-component claude.ai HTML artifacts using modern frontend web technologies (React, Tailwind CSS, shadcn/ui). Use for complex artifacts requiring state management, routing, or shadcn/ui components - not for simple single-file HTML/JSX artifacts.4license: Complete terms in LICENSE.txt5---67# Web Artifacts Builder89To build powerful frontend claude.ai artifacts, follow these steps:101. Initialize the frontend repo using `scripts/init-artifact.sh`112. Develop your artifact by editing the generated code123. Bundle all code into a single HTML file using `scripts/bundle-artifact.sh`134. Display artifact to user145. (Optional) Test the artifact1516**Stack**: React 18 + TypeScript + Vite + Parcel (bundling) + Tailwind CSS + shadcn/ui1718## Design & Style Guidelines1920VERY IMPORTANT: To avoid what is often referred to as "AI slop", avoid using excessive centered layouts, purple gradients, uniform rounded corners, and Inter font.2122## Quick Start2324### Step 1: Initialize Project2526Run the initialization script to create a new React project:27```bash28bash scripts/init-artifact.sh <project-name>29cd <project-name>30```3132This creates a fully configured project with:33- ✅ React + TypeScript (via Vite)34- ✅ Tailwind CSS 3.4.1 with shadcn/ui theming system35- ✅ Path aliases (`@/`) configured36- ✅ 40+ shadcn/ui components pre-installed37- ✅ All Radix UI dependencies included38- ✅ Parcel configured for bundling (via .parcelrc)39- ✅ Node 18+ compatibility (auto-detects and pins Vite version)4041### Step 2: Develop Your Artifact4243To build the artifact, edit the generated files. See **Common Development Tasks** below for guidance.4445### Step 3: Bundle to Single HTML File4647To bundle the React app into a single HTML artifact:48```bash49bash scripts/bundle-artifact.sh50```5152This creates `bundle.html` - a self-contained artifact with all JavaScript, CSS, and dependencies inlined. This file can be directly shared in Claude conversations as an artifact.5354**Requirements**: Your project must have an `index.html` in the root directory.5556**What the script does**:57- Installs bundling dependencies (parcel, @parcel/config-default, parcel-resolver-tspaths, html-inline)58- Creates `.parcelrc` config with path alias support59- Builds with Parcel (no source maps)60- Inlines all assets into single HTML using html-inline6162### Step 4: Share Artifact with User6364Finally, share the bundled HTML file in conversation with the user so they can view it as an artifact.6566### Step 5: Testing/Visualizing the Artifact (Optional)6768Note: This is a completely optional step. Only perform if necessary or requested.6970To test/visualize the artifact, use available tools (including other Skills or built-in tools like Playwright or Puppeteer). In general, avoid testing the artifact upfront as it adds latency between the request and when the finished artifact can be seen. Test later, after presenting the artifact, if requested or if issues arise.7172## Reference7374- **shadcn/ui components**: https://ui.shadcn.com/docs/components
Full transparency — inspect the skill content before installing.