Skip to content
🤔 Documentation issue? Report or edit

Slider

Info

This is the API of version 1.0.0-beta07

“Sliders allow users to make selections from a range of values.”

@Composable
fun MySliderDemo() {
    var sliderPosition by remember { mutableStateOf(0f) }
    Text(text = sliderPosition.toString())
    Slider(value = sliderPosition, onValueChange = { sliderPosition = it })
}

See also:


Last update: May 24, 2021