1. components
  2. switch
  3. svelte

Switch

A control for toggling between checked states.

List

Default to the inactive state.


Default to the active state.


Shown in disabled mode.

Icons

Pass icons through the inactiveChild and activeChild snippets respectively.

Compact

Apply the compact prop to switch a minimal display.

Lightswitch

This is a full fledge example using multiple features.