HorizontalSeparator

fun HorizontalSeparator(color: Color, modifier: Modifier = Modifier, thickness: Dp = Dp.Hairline)

Creates a horizontal separator line.

For interactive preview & code examples, visit Separators Documentation.

Basic Example

Column {
Text("Item 1")
Separator() // Horizontal separator in Column
Text("Item 2")
}

Row {
Text("Item 1")
Separator() // Vertical separator in Row
Text("Item 2")
}

Parameters

color

The color of the separator line.

modifier

Modifier to be applied to the separator.

thickness

The thickness of the separator line.