# Switch

> Controlled or uncontrolled boolean setting.

**BuildSpace v2.** Read https://ui.buildspace.studio/design.md first. Setup (fonts and namespace): https://ui.buildspace.studio/#install. The theme replaces Ink & Paper; review CSS changes before reinstalling in an existing project.

- **Name:** `switch`
- **Type:** component (`registry:ui`)
- **Registry item:** https://ui.buildspace.studio/r/switch.json

## Install

```sh
npx shadcn add https://ui.buildspace.studio/r/switch.json
```

## Dependencies

npm packages (installed automatically): `radix-ui`

Registry items (installed automatically by the shadcn CLI):

- `@buildspace/buildspace` — BuildSpace item, see https://ui.buildspace.studio/r/buildspace.md

> **Required first step:** add a `registries.@buildspace` entry to your project's `components.json` (`"@buildspace": "https://ui.buildspace.studio/r/{name}.json"`) before running the install command above — the shadcn CLI needs it to resolve the `@buildspace/*` dependency names above, even though this item itself installs from a full URL.

## Files

- `registry/new-york/switch/switch.tsx`
