ForgeUIPREMIUM ECOSYSTEM
Docs/Getting Started/CLI Commands

CLI Commands

Full reference for the ForgeUI CLI tool.

CLI Reference

The ForgeUI CLI (forgeui) is a command-line tool for managing components, themes, and project configuration.

Installation

The CLI runs via npx — no global install needed:

bash
npx forgeui <command>

Commands

#### init — Initialize Project

Sets up ForgeUI in an existing Next.js project:

bash
npx forgeui init

What it does: - Creates forgeui.config.ts configuration file - Adds design tokens to globals.css - Installs required npm dependencies - Sets up the cn() utility helper - Configures TypeScript path aliases

Options:

FlagDescriptionDefault
--typescriptUse TypeScript templatestrue
--src-dirSource directory path./src
--themeInitial theme presetmodern

#### add — Add Component

Installs a component into your project:

bash
npx forgeui add <component-name>

# Examples:
npx forgeui add button
npx forgeui add modal
npx forgeui add pricing

What it does: - Copies the component source file to src/components/ui/ - Installs any missing peer dependencies - Warns if the component already exists


#### theme — Apply Theme

Switches your project's color theme:

bash
npx forgeui theme <theme-name>

# Examples:
npx forgeui theme cyberpunk
npx forgeui theme neon
npx forgeui theme minimal

Available themes: modern, glass, neon, cyberpunk, luxury, corporate, minimal, nature, pastel, monochrome


#### list — List Available Resources

Lists all available components, templates, or themes:

bash
npx forgeui list components
npx forgeui list templates
npx forgeui list themes