- Docs
- Components
- Switch
Switch
A control that allows the user to toggle between on and off.
Preview
Code
Installation
CLI
Manual
Copy and paste the following code into your project.
Update the import paths to match your project setup.
Usage
Single import
Multiple imports
Examples
Form
Preview
Code
API Reference
Root
Prop | Type | Default |
---|---|---|
defaultSelected | boolean | false |
isSelected | boolean | false |
onChange | function |