# Switch

Render the shared immediate-toggle switch control. The digital equivalent of flipping a light switch.

## Notes

- Use Switch for settings toggles that read as on/off.
- Pair it with surrounding context that explains the effect. What exactly are we turning on here?

## Properties

| Name | Type | Default | Description |
| ---- | ---- | ------- | ----------- |
| id (required) | `string` | - | Unique ID. |
| label (required) | `string` | - | Label for the switch. |
| disabled | `boolean` | false | Whether the switch is disabled. |
| checked | `boolean` | false | Whether the switch is checked. |
| class | `string` | - | Additional CSS classes. |

## Example

```astro
<Switch id="announcements" label="Enable announcements" />
```
