Back to Components
Components
Image Comparison
Before and after image comparison with a draggable slider handle.
BeforeAfter
Dependencies
- clsx
- tailwind-merge
Files
- components/ui/image-comparison.tsx
Installation
Using shadcn CLI
npx shadcn add image-comparison --url https://ui.hampton.ioManual installation
Copy the component file to your project and install dependencies:
npm install clsx tailwind-merge