components/toggle

Toggle

A switch for instantly applying a setting, with label and sizes.

Usageimport { Toggle } from "./Toggle";
1import { Toggle } from "./Toggle";
2 
3<Toggle />

Copy the source with the toolbar’s copy button — or open the Code pane to select it by hand — then paste the file into your project. It is self-contained, with no registry metadata and no dependencies (Tailwind classes required).

Props

PropTypeDefault
labelstringEmail notifications
defaultCheckedbooleantrue
sizesm | mdmd
disabledbooleanfalse