shadcn-syntax-selectors

Select the correct shadcn UI selector primitive for form-binding scenarios.

Updated May 19, 2026
One-click install
npx skills add https://github.com/Impertio-Studio/shadcn-ui-Claude-Skill-Package --skill shadcn-syntax-selectors
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: shadcn-syntax-selectors
Source: https://github.com/Impertio-Studio/shadcn-ui-Claude-Skill-Package/tree/main/skills/source/shadcn-syntax/shadcn-syntax-selectors
Command: npx skills add https://github.com/Impertio-Studio/shadcn-ui-Claude-Skill-Package --skill shadcn-syntax-selectors

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Prevents predictable UX and integration failures when selecting between shadcn UI’s four “value picking” primitives (Native <select>, shadcn Select/Radix Select, Combobox, and Command palette), especially when React Hook Form binding and accessibility contracts are easy to get wrong.

Core Features & Use Cases

  • Decision tree for the right primitive: Chooses Native <select>, shadcn Select, Combobox, or Command palette based on list size, searchability/async loading needs, mobile-native picker expectations, and palette UX (Cmd+K).
  • Correct form-binding contracts: Enforces that Native <select> uses react-hook-form register, while shadcn Select and Combobox use Controller (to avoid swallowed onValueChange / missing controlled state).
  • Battle-tested wiring & a11y requirements: Guards against missing SelectValue, missing Popover modal=true in Combobox recipes, missing CommandDialog for palettes, and incorrect aria attributes for trigger/list behavior.
  • Async combobox state handling: Ensures loading/empty/error states are mutually exclusive so users don’t see “No results” during an in-flight request.

Quick Start

Ask Claude to “Recommend the correct shadcn selector for a searchable async list bound to React Hook Form, and generate the correct component wiring and a11y attributes.”

Frequently Asked Questions about shadcn-syntax-selectors

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I choose between a shadcn Combobox and a Radix Select for a searchable list?

Choose a shadcn Combobox for searchable or async-loaded option lists, and use a Radix Select for medium-to-large static lists where native search isn't required. A command palette serves app-wide Cmd+K actions rather than form fields.

Does React Hook Form work with shadcn Select components?

React Hook Form works with shadcn Select, but you must use the Controller component instead of the register function. Using register with Radix-based Select or Combobox components causes onValueChange to be swallowed and controlled state to be lost.

Why does my shadcn Combobox show "No results" during async loading?

Shadcn Combobox shows "No results" during async loading because loading, empty, and error states are not mutually exclusive. Proper async tri-state rendering ensures users see a loading indicator during in-flight requests instead of an empty results message.

What's the best way to handle accessibility wiring for a shadcn command palette?

The best way to handle command palette accessibility is to use the CommandDialog component and apply correct aria attributes for trigger and list behavior. This enforces the required component contracts for accessible app-wide action palettes.

When do I need a native HTML select element instead of a shadcn Select?

You need a native HTML select element when mobile-native picker expectations are a priority. Native select elements use the react-hook-form register function for form binding, unlike shadcn Select components which require Controller.

What Popover modal setting is required for a shadcn Combobox?

A shadcn Combobox requires the Popover modal prop to be set to true. This prevents layout and interaction issues, ensuring the component contract is met when rendering searchable dropdowns within forms.