---
title: "Adding components"
description: "Install components, utilities, and features from the registry with nimbus-docs add."
---

> Documentation Index
> Fetch the complete documentation index at: https://docs.klounge.kr/llms.txt
> Use this file to discover all available pages before exploring further.

# Adding components

`nimbus-docs add <slug>` installs from the [registry](/registry). It works in two modes depending on what you're adding — files copy in, or a recipe hands off to a coding agent.

## Components and utilities

For `registry:ui` and `registry:lib` slugs, the CLI resolves dependencies, copies files into your repo, and installs any npm packages they need:

```sh
npx add accordion
pnpm dlx add accordion
yarn dlx add accordion
bunx add accordion
```

1. **Resolve dependencies**

   The CLI walks the slug's `registryDependencies` and npm `dependencies` transitively.
2. **Copy files**

   Each file lands at its declared path — `src/components/ui/<slug>/`, `src/lib/`, etc.
3. **Register globals**

   Components used in MDX without an import must be added to `src/components.ts`. The CLI tells you which.

Once installed, the component lives in your repo — edit it freely. Pass `--yes` to skip overwrite prompts.

## Features

For `registry:feature` slugs there's nothing to copy. The recipe is a Markdown prompt a coding agent reads, adapts to your project, and applies:

```sh
npx add 404-page
pnpm dlx add 404-page
yarn dlx add 404-page
bunx add 404-page
```

If a coding agent is detected in the environment, the CLI prints the recipe to stdout for it to consume. Otherwise pipe it yourself:

```sh
npx add 404-page --print | claude
pnpm dlx add 404-page --print | claude
yarn dlx add 404-page --print | claude
bunx add 404-page --print | claude
```

## Browse what's available

```sh
npx list
pnpm dlx list
yarn dlx list
bunx list
```
```sh
npx list --type ui
pnpm dlx list --type ui
yarn dlx list --type ui
bunx list --type ui
```

Every shipped component also has a showcase at [/components](/components) — preview, props, and the install command. See the [CLI](/cli) reference for all flags.

Source: https://docs.klounge.kr/adding-components/index.mdx
