Switch
======

*   GitHub: [BonnierNews/dn-design-system/web/src/components/switch](https://github.com/BonnierNews/dn-design-system/tree/main/web/src/components/switch)
*   Storybook: [Checkbox](https://designsystem.dn.se/?path=/docs/basic-form-switch--docs)

The component will not include styling by itself. Make sure to include the right styles for the component. See example below: `@use '@bonniernews/dn-design-system-web/components/switch/switch.scss`

| Name | Description | Default |
|:--- | :--- | :--- |
| name | string | "ds-switch" |
| showMeta | boolean | false |
| metaOn | string | "På" |
| metaOff | string | "Av" |
| stripLabel | boolean | \- |
| checked | boolean | \- |
| required | boolean | \- |
| disabled | boolean | \- |
| validation | string | \- |
| forcePx | boolean | \- |
| classNames | Ex. "my-special-class"<br />string | \- |
| attributes | Ex. { target: "\_blank", "data-test": "lorem ipsum" }<br />Record<string, unknown> | \- |

```jsx
<Switch
  name="switch1"
/>
```