Ariakit
/

combobox-item-value

Open preview in a new tab
Edit withViteNext.js
import * as Ariakit from "@ariakit/react";
import "./style.css";
const fruits = ["Apple", "Grape", "Orange", "Strawberry", "Watermelon"];
export default function Example() {
const combobox = Ariakit.useComboboxStore();
return (
<>
<Ariakit.ComboboxLabel store={combobox} className="label">
Your favorite fruit
store={combobox}
placeholder="e.g., Apple"
className="combobox"
/>
store={combobox}
gutter={8}
className="popover"
>
{fruits.map((f) => (
<Ariakit.ComboboxItem key={f} value={f} className="combobox-item">
))}
</>
);
}

Stay tuned

Join 1,000+ subscribers and receive monthly tips & updates on new Ariakit content.

No spam. Unsubscribe anytime. Read latest issue