React Hook Form + Zod
- from @flx
Controller binds the switch to RHF; Zod requires opt-in on submit.
Install
New to shadcn? Set up your project
If your project already has a shadcn components.json, skip initialization. Otherwise, run this once from your project root.
pnpm dlx shadcn@latest initpnpm dlx shadcn@latest add @flx/switch-12Registry dependencies3
- switch
- field
- button
