--- title: Button description: Displays a button or a component that looks like a button. featured: true component: true --- ## Installation CLI Manual ```bash npx shadcn-ui@latest add button ``` Install the following dependencies: ```bash npm install @radix-ui/react-slot ``` Copy and paste the following code into your project. Update the import paths to match your project setup. ## Usage ```tsx import { Button } from "@/components/ui/button" ``` ```tsx ``` ## Link You can use the `buttonVariants` helper to create a link that looks like a button. ```tsx import { buttonVariants } from "@/components/ui/button" ``` ```tsx Click here ``` Alternatively, you can set the `asChild` parameter and nest the link component. ```tsx ``` ## Examples ### Primary ### Secondary ### Destructive ### Outline ### Ghost ### Link ### Icon ### With Icon ### Loading ### As Child