Skip to content

Collapsible

An interactive component that can be expanded or collapsed to show or hide content. Lighter than Accordion — best for single items.

$cookest-ui add collapsible

Basic

A simple collapsible section for recipe tips.

Chef's Tips

Always use guanciale, not bacon.

Ingredient Notes

Use Collapsible to progressively reveal substitution information.

GuancialePancetta or thick-cut bacon
Pecorino RomanoParmigiano Reggiano
Egg yolks onlyWhole eggs (lighter result)
PropTypeDefaultDescription
openbooleanControlled open state.
onOpenChange(open: boolean) => voidCallback when open state changes.
defaultOpenbooleanfalseUncontrolled default open state.
CollapsibleTriggerReactNodeElement that toggles the collapsible. Supports asChild.
CollapsibleContentReactNodeThe content shown/hidden based on open state.