switch-demo

PreviousNext
Docs
takiexample

Preview

Loading preview…
registry/new-york/examples/switch-demo.tsx
import { Label } from "@/registry/new-york/ui/label"
import { Switch } from "@/registry/new-york/ui/switch"

export default function SwitchDemo() {
  return (
    <div className="flex items-center space-x-2">
      <Switch id="airplane-mode" />
      <Label htmlFor="airplane-mode">Airplane Mode</Label>
    </div>
  )
}

Installation

npx shadcn@latest add @taki/switch-demo

Usage

import { SwitchDemo } from "@/components/switch-demo"
<SwitchDemo />