Imported from Knuckles-Team/universal-skills (
universal_skills/web-development/web-artifacts/SKILL.md). Install upstream withnpx skills add Knuckles-Team/universal-skills --skill web-artifacts. Copyright stays with the author (MIT).
Web & UI Artifacts
Overview
This skill unifies guidelines and tooling for building frontend web artifacts.
Design Discovery (Phase 1)
Before scaffolding, identify:
- Core Narrative: What story does this artifact tell?
- Interactive Depth: Does the user need to filter, drill-down, or just observe?
- Visual Aesthetic: Map to a preset (see
website-builderPresets A-D).
Artifact Design Principles
- Self-Contained: Artifacts must be portable. Use CDNs for heavy libraries (React, D3, GSAP).
- Interactive Data Visualization: Use D3.js or SVG for complex data representations.
- Motion for Meaning: Use GSAP to reveal relationships between data points, not just for decoration.
- Accessibility: Maintain high contrast and keyboard navigability.
Capabilities/Tools
We provide scripts to scaffold and bundle interactive React components using shadcn/ui and Tailwind.
scripts/init-artifact.sh: Initializes a new frontend project structure.scripts/bundle-artifact.sh: Bundles the React project into a single interactive HTML file.
# Example
bash scripts/init-artifact.sh my-new-component
bash scripts/bundle-artifact.sh my-new-component
Design Guidelines & Workflows
The docs/ folder contains reference materials and standard operating procedures for achieving high-quality design outcomes:
- Brand Guidelines: Always consult brand requirements when selecting colors, typography, or component styles.
- Figma Implementation: When given a Figma design or mock, refer to the documentation to correctly map tokens to Tailwind classes.
- Frontend Architecture: Ensure functional components are used, React hooks are managed properly, and the design is mobile-responsive.
- Agent UI Capabilities: Make sure to use single-file HTML/JS bundles generated by the builder scripts to ensure compatibility with agentic browser tools.