figma_ds_scaffold
Generate a design-system package skeleton from completed Figma analysis and token extraction, including package.json, component layout, token files, docs page, and README.
Instructions
Generate the design-system package skeleton at outDir from a completed analysis + token extraction: package.json (app framework as peer deps), src/components layout, token files via the shared formatter engine, a framework-neutral token-showcase MDX docs page (the bird's-eye view), and a README with the workflow. Storybook itself is NOT installed by this tool — after scaffolding, run npm create storybook@latest inside outDir (the CLI auto-detects the framework and installs the current Storybook version). Additive by default: existing files are skipped unless force. Local Mode only.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| force | No | Overwrite existing scaffold files (token files always refresh). | |
| outDir | Yes | The outDir used in figma_ds_analyze / figma_ds_extract_tokens. | |
| formats | No | Token formats to (re)generate under tokens/. | |
| framework | No | Override the scaffold framework. Default: the first framework detected by figma_ds_analyze. Note: Storybook has no .astro renderer — 'astro' scaffolds a react-vite workshop whose stories mirror the component markup. | |
| dtcgDialect | No | DTCG dialect for dtcg/json outputs. | legacy |
| packageName | No | npm package name for the design system (e.g. '@acme/design-system'). Default: '@extracted/design-system'. |