Theme

CLI

The CLI handles setup snippets, component scaffolding, composed-output source retrieval, lookup, and validation. Build it from a checkout and run node packages/cli/dist/index.js for deterministic plain-text workflows that work well for both humans and agents.

Command reference

Until npm publishing is live, use the repo-local CLI entrypoint after bun run --filter '@dryui/cli' build. It gives you plain-text output optimized for LLMs and humans and complements the DryUI skill plus MCP workflow.

init

Print theme, theme-auto, and linked-development setup snippets.

bash
node packages/cli/dist/index.js init
add

Print a copyable starter snippet with the correct import and compound structure.

bash
node packages/cli/dist/index.js add Card --with-theme
get

Print copyable Svelte source for a composed output from the catalog.

bash
node packages/cli/dist/index.js get "Checkout Forms"
info

Get the full component API reference (props, parts, CSS vars, and an example).

bash
node packages/cli/dist/index.js info card
list

Browse components by category.

bash
node packages/cli/dist/index.js list --category layout
review

Validate a Svelte file against the DryUI spec.

bash
node packages/cli/dist/index.js review src/routes/+page.svelte
diagnose

Diagnose a theme CSS file for missing tokens, value errors, and contrast/visibility issues.

bash
node packages/cli/dist/index.js diagnose src/app.css

Workflow map

Use the docs site for setup and source browsing, then fall back to the CLI when you want the same information in a plain-text form that agents can parse deterministically.

setup

Theme imports, theme-auto, local-linking guidance, and form validation recipes live on the Getting Started page.

components

The component docs page shows props, bindable fields, structure notes, examples, and CSS hooks for each Svelte component.

source-backed outputs

Blocks, templates, and starter-kit pages expose the actual copyable Svelte source for composed outputs and reusable starters.

Static Docs

Use the static LLM endpoints when an agent or retrieval system needs project-wide DryUI context without starting a CLI or MCP process.

llms.txt

Library overview, setup, categories, and compact component summaries.

/llms.txt
llms-components.txt

Detailed component imports, props, CSS variables, data attributes, and examples.

/llms-components.txt

CLI vs MCP

Prefer the CLI when you need deterministic component knowledge and source browsing. Prefer MCP when you want automated code/theme analysis inside an agent workflow.