Divider

It's a line.

<script>
	import { Divider } from '$lib/components/divider';
</script>

<Divider />

Component API

PropDefaultDescription
Divider extends the JSX <hr> element
softfalseWhether the divider should use a softer color.

Examples

Basic example

Use the Divider component to add a horizontal rule between items:

<script>
	import { Divider } from '$lib/components/divider';
</script>

<Divider />

With reduced contrast

Use the soft prop for secondary dividers:

<script>
	import { Divider } from '$lib/components/divider';
</script>

<Divider soft />

With spacing

Use utility classes like my-* to control the vertical spacing around a divider:

<script>
	import { Divider } from '$lib/components/divider';
</script>

<Divider class="my-6" />