Homecomponentsaction

Alpha
This component is in development. There could be breaking changes made to it in a non-major release of Prism. Please use with caution.

Use Switch to view or switch between enabled or disabled states.

Disabled

Use the disabled property to prevent any interaction with the switch.

Example

Settings


API

id
The HTML id of the switch.
string

disabled
Used to disable the switch.
true
false

on
State of the switch.
true
false

onChange
Called when the switch is toggled.
((checked: boolean) => void)

data
An object with the data keys and values.
DataAttributeMap