Arrow Button

A call-to-action whose arrow slides or grows on hover. Pure CSS.

no dependenciesMIT · free

Installation

npx shadcn@latest add https://ombakui.com/r/arrow-button.json

Usage

import { ArrowButton } from "@/components/arrow-button";

<ArrowButton>Start building</ArrowButton>
<ArrowButton as="a" href="/docs" variant="grow">Read the docs</ArrowButton>

Props

PropTypeDefaultDescription
asT"button"Render as another element, e.g. "a".
children*ReactNode–Button content.
variant"slide" | "grow""slide""slide" swaps the arrow out and in; "grow" draws a stem behind the arrow head.
classNamestring–