Open vvdrak opened 1 year ago
This code has an excessive recomposition for the RatingBar when you type the text
@Composable private fun Foo() { Column(modifier = Modifier.padding(20.dp)) { var rating by remember { mutableFloatStateOf(0f) } var feedback by remember { mutableStateOf("") } RatingBar( value = rating, painterEmpty = painterResource(id = R.drawable.ic_star_off), painterFilled = painterResource(id = R.drawable.ic_star_on), onValueChange = { rating = it }, onRatingChanged = {} ) TextField(value = feedback, onValueChange = { feedback = it }) } }
Painter is unstable param. Check SO for resolve this problem.
Painter
@vvdrak thanks. will fix this
This code has an excessive recomposition for the RatingBar when you type the text
Painter
is unstable param. Check SO for resolve this problem.