Toast

Overlays & Feedback

macOS Notification Center style HUD alert toasts.

Installation

$npx shadcn-macos@latest add toast

Examples

Props

<ToastProvider />
PropTypeDefaultDescription
children*React.ReactNodeApplication component tree.
useToast() Hook
PropTypeDefaultDescription
toast({ title, description, type, duration })(options: { title: string; description?: string; type?: 'default' | 'success' | 'error' | 'warning'; duration?: number }) => voidTriggers a new toast notification HUD.
dismiss(id)(id: string) => voidDismisses an active toast by its unique ID.