rememberPickerState
Composable Function
Android
@Composable
public fun rememberPickerState(
initialNumberOfOptions: Int,
initiallySelectedOption: Int = 0,
repeatItems: Boolean = true,
): PickerState
Creates a PickerState
that is remembered across compositions.
Parameters
initialNumberOfOptions | the number of options |
initiallySelectedOption | the option to show in the center at the start |
repeatItems | if true (the default), the contents of the component will be repeated |