Package Exports
- @fluentui/react-switch
Readme
@fluentui/react-switch
React Switch components for Fluent UI React
The Switch
control (formerly Toggle
) enables users to trigger an option on or off through pressing on the component.
STATUS: WIP 🚧
These are not production-ready components and should never be used in product. This space is useful for testing new components whose APIs might change before final release.
Usage
To import Switch:
import { Switch } from '@fluentui/react-switch';
Once the Switch component graduates to a production release, the component will be available at:
import { Switch } from '@fluentui/react-components';
Examples
<Switch />
<Switch defaultChecked={true} />
<Switch checked={switchValue} onChange={switchOnChange} />
<Switch disabled />