Skip to content

Instantly share code, notes, and snippets.

@andreymusth
Created Aug 13, 2021
Embed
What would you like to do?
animate color as state
val color by animateColorAsState(
targetValue = if (isSelected) {
Color.White
} else {
Color.Black
},
animationSpec = tween(durationMillis = 100, easing = LinearEasing)
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment