Skip to content

Checkbox

Display a checkbox field.

Usage

Use a v-model to make the Checkbox reactive.

vue
<script setup>
import {ref} from 'vue';

const selected = ref(true)
</script>

<template>
  <s-checkbox v-model="selected" name="notifications" label="Notifications"/>
</template>

Label

Use the label prop to display a label on the right.

vue
<script setup>
import {ref} from 'vue';

const selected = ref(true)
</script>

<template>
  <s-checkbox v-model="selected" label="Label"/>
</template>

Released under the MIT License.