Skip to content

Instantly share code, notes, and snippets.

@victorbrndls
Created October 19, 2021 21:39
Show Gist options
  • Save victorbrndls/963d8e4ff29eb33d52cf6e86dbdb9748 to your computer and use it in GitHub Desktop.
Save victorbrndls/963d8e4ff29eb33d52cf6e86dbdb9748 to your computer and use it in GitHub Desktop.
val color = remember { Animatable(Color.Gray) }
LaunchedEffect(ok) { color.animateTo(if (ok) Color.Green else Color.Red) }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment