# Shadcn Basic

> A basic combobox with a list of options

- Type: example, free and open source (MIT)
- Component: [Combobox](https://reui.io/components/combobox.md)
- Page: https://reui.io/components/combobox/c-combobox-1
- Docs (Base UI): https://ui.shadcn.com/docs/components/base/combobox.md
- Docs (Radix UI): https://ui.shadcn.com/docs/components/radix/combobox.md
- MCP: `get_example("c-combobox-1")`
- Registry item: https://reui.io/r/styles/base-nova/c-combobox-1.json
- Uses: Combobox, Field

## Best for

The minimal single pick wiring: a string array filtered by typing, with a no results message

## When not to use

- Options sorted under headings such as world regions: use [Grouped Options](https://reui.io/components/combobox/c-combobox-6.md) (`get_example("c-combobox-6")`)

## Install

```bash
npx shadcn@latest add @reui/c-combobox-1
```

## About Shadcn Combobox

### When to use

- Form fields that pick one option by typing to search, such as a framework, timezone or country
- Fields holding several picks as chips, such as frameworks or team members with avatars
- Task property pickers opened from a button, such as status, priority, assignee, labels, team or due date

### When not to use

- A short fixed list chosen from a button, with no typing to narrow it: use [Select](https://reui.io/components/select.md) (`get_component("select")`)
- A free text field that suggests matches but keeps whatever was typed: use [Autocomplete](https://reui.io/components/autocomplete.md) (`get_component("autocomplete")`)
- A complete signup or settings page with many fields and a submit row: use the [Form blocks](https://reui.io/blocks/application/form.md)

### Agent notes

- Rows filter as the user types only when the function child of `ComboboxList` renders them; static `ComboboxItem` children always stay listed
- `itemToStringValue` sets only the submitted value; without itemToStringLabel, search matches an object item's label, else its value field, else its JSON
- Combobox parts take `render` in both twins, since both wrap `@base-ui/react`; `asChild` applies only to radix twin parts such as `DialogTrigger` and `Button`

Every ReUI item has a twin like this one; the index is https://reui.io/llms.txt. Agents with the ReUI MCP (https://reui.io/docs/mcp) get the same guidance from the getters named above.
