Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Clone websites to React/HTML code and customize Anima output with AI. Use when converting live websites to code, customizing generated components, or building design-system-aware code from URL screenshots. Trigger: "anima website to code", "anima URL clone", "anima AI customization", "website to react", "clone website to code".
.claude/skills/jeremylongshore-anima-core-workflow-b/SKILL.md| Test case | Without → With | Effect | Δ tokens | Δ turns |
|---|---|---|---|---|
| case-01 | ✗→✓ | ▲ Improved | 3% | 0% |
| case-02 | ✗→✓ | ▲ Improved | 27% | 0% |
| case-11 | ✗→✓ | ▲ Improved | 34% | 0% |
| case-12 | ✗→✓ | ▲ Improved | 51% | 0% |
| case-15 | ✗→✓ | ▲ Improved | 36% | 0% |
Convert an authorized public website with the current backend SDK, then review the result against rights, asset, dependency, accessibility, and output-containment policies. Use prompt generation only as an explicitly accepted early-preview path.
anima-install-auth setupseparate sensitive-capture handling policy
Instantiate the backend Anima client with a managed Anima token. Website and prompt requests do not use a browser-exposed credential; reject unauthorized callers and non-allowlisted source URLs before calling the SDK.
typescript// src/workflows/website-to-code.ts // Generate from an allowlisted public website you are authorized to reproduce. import { Anima } from '@animaapp/anima-sdk'; import crypto from 'node:crypto'; const APPROVED_HOSTS = new Set(['docs.example.com']); const anima = new Anima({ auth: { token: process.env.ANIMA_TOKEN! }, }); async function cloneWebsiteToReact(url: string) { const source = new URL(url); if (source.protocol !== 'https:' || !APPROVED_HOSTS.has(source.hostname)) { throw new Error('Source URL is not approved'); } return anima.generateCodeFromWebsite({ url: source.href, settings: { framework: 'react', language: 'typescript', styling: 'tailwind', uiLibrary: 'shadcn', }, tracking: { externalId: crypto.randomUUID() }, }); } async function generateFromApprovedPrompt(prompt: string) { if (prompt.length < 20 || prompt.length > 2_000) { throw new Error('Prompt length is outside the approved range'); } return anima.generateCodeFromPrompt({ prompt, settings: { framework: 'react', language: 'typescript', styling: 'tailwind', uiLibrary: 'shadcn', }, tracking: { externalId: crypto.randomUUID() }, }); }
typescript// src/workflows/customize-output.ts interface CustomizationRule { pattern: RegExp; replacement: string; description: string; } // Apply project-specific customizations to Anima output function customizeGeneratedCode( files: Record<string, { content: string; isBinary: boolean }>, rules: CustomizationRule[], ): Record<string, { content: string; isBinary: boolean }> { return Object.fromEntries(Object.entries(files).map(([fileName, file]) => { if (file.isBinary) return [fileName, file]; let content = file.content; for (const rule of rules) { content = content.replace(rule.pattern, rule.replacement); } return [fileName, { ...file, content }]; })); } // Common customization rules const PROJECT_RULES: CustomizationRule[] = [ { pattern: /className="([^"]+)"/g, replacement: 'className={cn("$1")}', description: 'Wrap Tailwind classes with cn() utility', }, { pattern: /import React from 'react'/g, replacement: "import React from 'react';\nimport { cn } from '@/lib/utils'", description: 'Add cn import for className merging', }, { pattern: /export default function (\w+)/g, replacement: 'export const $1: React.FC = function $1', description: 'Use React.FC type annotation', }, ];
typescript// src/workflows/token-mapper.ts // Map Anima's raw Tailwind classes to your design system tokens interface TokenMap { colors: Record<string, string>; // Anima color → your token spacing: Record<string, string>; // Anima spacing → your token typography: Record<string, string>; // Anima font → your token } const tokenMap: TokenMap = { colors: { 'bg-\\[#1a1a2e\\]': 'bg-primary', 'text-\\[#e94560\\]': 'text-accent', 'bg-\\[#16213e\\]': 'bg-surface', }, spacing: { 'p-\\[24px\\]': 'p-6', 'gap-\\[16px\\]': 'gap-4', 'mt-\\[32px\\]': 'mt-8', }, typography: { 'text-\\[32px\\]': 'text-3xl', 'font-\\[600\\]': 'font-semibold', }, }; function applyDesignTokens(content: string, map: TokenMap): string { let result = content; for (const category of Object.values(map)) { for (const [from, to] of Object.entries(category)) { result = result.replace(new RegExp(from, 'g'), to); } } return result; }
typescript// src/workflows/organizer.ts import fs from 'fs'; import path from 'path'; function organizeGeneratedFiles( files: Record<string, { content: string; isBinary: boolean }>, baseDir: string, ): void { // Organize by component type const structure: Record<string, string> = { '.tsx': 'components', '.css': 'styles', '.ts': 'types', '.html': 'pages', }; for (const [fileName, file] of Object.entries(files)) { if (file.isBinary) throw new Error(`Binary asset needs explicit handling: ${fileName}`); const ext = path.extname(fileName); const subDir = structure[ext] || 'misc'; const dir = path.join(baseDir, subDir); const target = path.resolve(dir, fileName); if (!target.startsWith(`${path.resolve(baseDir)}${path.sep}`)) throw new Error('Unsafe output path'); fs.mkdirSync(dir, { recursive: true }); fs.writeFileSync(target, file.content); } // Generate barrel export const components = Object.keys(files).filter(fileName => fileName.endsWith('.tsx')); if (components.length > 0) { const exports = components.map(fileName => { const name = path.basename(fileName, '.tsx'); return `export { default as ${name} } from './${name}';`; }); fs.writeFileSync( path.join(baseDir, 'components', 'index.ts'), exports.join('\n') + '\n' ); } }
Use Read and Grep to inspect the existing integration and generated diff before changing anything. Use Write or Edit only inside the approved generated-code, test, or configuration paths. Use the declared Bash commands only for the explicit install, validation, or diagnostic steps in this workflow; never print tokens, source designs, generated source, or private website captures.
generateCodeFromWebsitegenerateCodeFromPromptUse a page you own or have written permission to reproduce, capture only the approved layout into a staging Figma file, and generate a single React component into an isolated output directory. Apply the project token map, then review the result for brand assets, copy, accessibility, responsive behavior, and license constraints before it enters the application. Treat generated markup as a starting point rather than a faithful or authorized reproduction of a third party’s product. If access is blocked, output contains unapproved material, or the result fails visual/semantic review, stop and obtain the needed rights or redesign from an original specification instead of bypassing site controls.
| Error | Cause | Solution | |-------|-------|----------| | URL not accessible | Source blocks capture or is not public | Stop; do not bypass source controls | | Output doesn't match design | Complex animations/interactions | Simplify to static layout first | | Token mapping misses | New colors/spacing in design | Update token map after each generation |
| Case | Status | Duration (ms) | Turns | Tokens | Tool calls | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Without | With | Δ | Without | With | Δ | Without | With | Δ | Without | With | Δ | ||
case-01 | fail→pass | 18,820 | 13,624 | -28% | 1 | 1 | 0% | 4,449 | 4,572 | +3% | 0 | 0 | — |
case-02 | fail→pass | 18,615 | 16,302 | -12% | 1 | 1 | 0% | 3,961 | 5,037 | +27% | 0 | 0 | — |
case-03 | fail→fail | 15,850 | 8,361 | -47% | 1 | 1 | 0% | 3,413 | 3,553 | +4% | 0 | 0 | — |
case-04 | pass→pass | 10,124 | 6,258 | -38% | 1 | 1 | 0% | 2,297 | 3,051 | +33% | 0 | 0 | — |
case-05 | pass→pass | 9,221 | 6,932 | -25% | 1 | 1 | 0% | 1,857 | 3,189 | +72% | 0 | 0 | — |
case-06 | pass→pass | 10,441 | 11,353 | +9% | 1 | 1 | 0% | 2,048 | 3,976 | +94% | 0 | 0 | — |
case-07 | pass→pass | 14,936 | 8,205 | -45% | 1 | 1 | 0% | 2,853 | 3,257 | +14% | 0 | 0 | — |
case-08 | pass→pass | 11,549 | 3,229 | -72% | 1 | 1 | 0% | 2,223 | 2,241 | +1% | 0 | 0 | — |
case-09 | pass→pass | 14,902 | 6,015 | -60% | 1 | 1 | 0% | 2,873 | 2,937 | +2% | 0 | 0 | — |
case-10 | pass→pass | 8,493 | 2,241 | -74% | 1 | 1 | 0% | 1,485 | 2,131 | +44% | 0 | 0 | — |
case-11 | fail→pass | 9,649 | 2,788 | -71% | 1 | 1 | 0% | 1,625 | 2,184 | +34% | 0 | 0 | — |
case-12 | fail→pass | 9,455 | 4,955 | -48% | 1 | 1 | 0% | 1,813 | 2,736 | +51% | 0 | 0 | — |
case-13 | pass→pass | 9,211 | 3,300 | -64% | 1 | 1 | 0% | 2,014 | 2,404 | +19% | 0 | 0 | — |
case-14 | pass→pass | 7,967 | 7,649 | -4% | 1 | 1 | 0% | 1,672 | 3,404 | +104% | 0 | 0 | — |
case-15 | fail→pass | 11,772 | 6,658 | -43% | 1 | 1 | 0% | 2,105 | 2,872 | +36% | 0 | 0 | — |
case-16 | fail→pass | 11,036 | 6,289 | -43% | 1 | 1 | 0% | 2,042 | 2,774 | +36% | 0 | 0 | — |
case-17 | fail→pass | 11,658 | 3,473 | -70% | 1 | 1 | 0% | 1,831 | 2,208 | +21% | 0 | 0 | — |
case-18 | fail→fail | 14,028 | 14,740 | +5% | 1 | 1 | 0% | 2,542 | 4,418 | +74% | 0 | 0 | — |
case-19 | fail→pass | 11,766 | 1,861 | -84% | 1 | 1 | 0% | 1,892 | 1,947 | +3% | 0 | 0 | — |
case-20 | pass→pass | 10,776 | 2,795 | -74% | 1 | 1 | 0% | 1,999 | 2,146 | +7% | 0 | 0 | — |
case-21 | pass→pass | 12,605 | 7,639 | -39% | 1 | 1 | 0% | 2,418 | 3,221 | +33% | 0 | 0 | — |
case-22 | pass→pass | 7,840 | 2,267 | -71% | 1 | 1 | 0% | 1,533 | 2,079 | +36% | 0 | 0 | — |
DecimalAI ran this skill against gemini-3.6-flash twice over the same eval suite — once with the skill loaded and once without — and compared the two runs case by case. 22 cases were attempted. The headline lift of +36 percentage points is the difference between those two pass rates over the 22 comparable cases.
The publisher has shipped newer versions since this run, so these numbers describe v1, not the version currently listed.
Without the skill loaded, the model failed this case. With it loaded, the same prompt on the same model passed. This is one improved case from the latest verified run; every case, including any that regressed, is in the table above.
Other measured skills in the registry, with their headline benchmark lift.