Loading...
Installation
Install the following dependencies:
Copy and paste the following code into your project.
Loading...
Update the import paths to match your project setup.
Composition
Alert ├── icon (optional) ├── AlertTitle ├── AlertDescription (optional) └── AlertAction (optional)
Examples
Default
Loading...
Destructive
Loading...
Title Only
Loading...
With Action
Loading...
With List
Loading...
API Reference
Alert
| Prop | Type | Default | Description |
|---|---|---|---|
variant | "default" | "destructive" | "default" | Controls the alert's visual treatment. |
Utilities and Supporting Types
| Export | API |
|---|---|
alertVariants | Style recipe used to reuse the component variants. |
Angular
React
Solid
Svelte
Vue