Docs
Label
Label
Renders an accessible label associated with controls.
Loading...
<script lang="ts">
import { Checkbox } from "@/components/ui/checkbox";
import { Label } from "@/components/ui/label";
</script>
<div>
<div class="flex items-center space-x-2">
<Checkbox id="terms" />
<Label for="terms">Accept terms and conditions</Label>
</div>
</div>
<script lang="ts">
import { Checkbox } from "@/components/ui/checkbox";
import { Label } from "@/components/ui/label";
</script>
<div>
<div class="flex items-center space-x-2">
<Checkbox id="terms" />
<Label for="terms">Accept terms and conditions</Label>
</div>
</div>
Installation
npx shadcn-svelte add label
Usage
<script lang="ts">
import { Label } from "$components/ui/label";
</script>
<Label for="email">Your email address</Label>
On This Page