GitHub's profile imagefasu.dev

Theme Switcher

A theme switcher component for light, dark, and system modes with Vercel Inc style.

Installation

npx shadcn@latest add https://registry.fasu.dev/r/theme-switcher.json

Usage

import { ThemeSwitcher } from "@/components/theme-switcher";
 
export default function Example() {
  return <ThemeSwitcher />
}

Ensure next-themes is configured in your _app.tsx or layout.tsx.

Dependencies

This component depends on:

  • lucide-react
  • next-themes

On this page