1 min read

BaseSwitch

BaseSwitch

Basic switch component to handle boolean values. This component receives its selected state using a prop, and emits a Vue event whenever the user clicks it.

Props

Name Description Type Default
value boolean

Events

Event name Properties Description
change
input

Events

This component emits no events.

See it in action

Here you have a basic example of how the switch is rendered.

Try clicking it to see how it changes its state

The switch component also supports using the v-model directive, to automatically handle its state change: