Sean Hello

ReUI Switch

Component

About

ReUI Switch with the first 10 official ReUI examples, preserved from the MIT-licensed source registry.

Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds ReUI Switch to your project and fits it to your theme.

Code

How ReUI Switch is used: the demo's code. The component's own source comes with a free account.

Usage.tsx

import { Field, FieldLabel } from "@/components/ui/reui-switch-utils/field"
import { Switch } from "@/components/ui/reui-switch"

export default function Pattern() {
  return (
    <Field className="w-auto">
      <FieldLabel>Notification Settings</FieldLabel>
      <Field orientation="horizontal">
        <Switch id="sg-email" defaultChecked />
        <FieldLabel htmlFor="sg-email">Email notifications</FieldLabel>
      </Field>
      <Field orientation="horizontal">
        <Switch id="sg-sms" />
        <FieldLabel htmlFor="sg-sms">SMS notifications</FieldLabel>
      </Field>
      <Field orientation="horizontal">
        <Switch id="sg-push" defaultChecked />
        <FieldLabel htmlFor="sg-push">Push notifications</FieldLabel>
      </Field>
    </Field>
  )
}

Dependencies