## `<w-switch>` API

Unless otherwise noted all properties are HTML attributes (as opposed to JavaScript object properties).

### Properties

| Name | Type | Default | Summary |
|-|-|-|-|
| checked | `boolean` | `false` | Whether the switch is on (checked). |
| disabled | `boolean` | `false` | Whether the switch is disabled. |
| name | `string` | `-` | Name used when submitting an HTML form. |
| resetFormControl (JS only) | `resetFormControl() => void` | `-` | - |
| value | `string` | `-` | Value submitted when the switch is checked. |

### Property Details

#### checked

Whether the switch is on (checked).

- Type: `boolean`
- Default: `false`

#### disabled

Whether the switch is disabled.

- Type: `boolean`
- Default: `false`

#### name

Name used when submitting an HTML form.

- Type: `string`
- Default: `-`

#### resetFormControl (JS only)



- Type: `resetFormControl() => void`
- Default: `-`

#### value

Value submitted when the switch is checked.

The component reports `null` as the value in the `change` event when `value` is an empty string.

- Type: `string`
- Default: `-`

### Events

#### change

Dispatched when the switch toggles. Includes boolean `checked` and string/null `value` on `details`.

- Type: `WarpSwitchChangeEvent`


