mattinger
06/22/2021, 1:14 PMAdam Powell
06/22/2021, 1:30 PMAdam Powell
06/22/2021, 1:32 PMAdam Powell
06/22/2021, 1:33 PMmattinger
06/22/2021, 1:35 PMAdam Powell
06/22/2021, 1:39 PMmattinger
06/22/2021, 1:40 PMAdam Powell
06/22/2021, 1:40 PMAdam Powell
06/22/2021, 1:41 PMmattinger
06/22/2021, 1:41 PMAdam Powell
06/22/2021, 1:43 PMLouis Pullen-Freilich [G]
06/22/2021, 1:55 PMAdam Powell
06/22/2021, 2:04 PMLouis Pullen-Freilich [G]
06/22/2021, 2:09 PMmattinger
06/22/2021, 2:12 PMAdam Powell
06/22/2021, 2:32 PMmattinger
06/22/2021, 2:43 PMmattinger
06/22/2021, 2:45 PMAdam Powell
06/22/2021, 2:46 PMmattinger
06/22/2021, 2:46 PMmattinger
06/22/2021, 2:52 PMmattinger
06/22/2021, 3:02 PMAdam Powell
06/22/2021, 5:07 PMAdam Powell
06/22/2021, 5:07 PMDominaezzz
06/22/2021, 5:31 PMremember
that derivedStateOf
.Adam Powell
06/22/2021, 5:49 PMAdam Powell
06/22/2021, 5:53 PMderivedStateOf
isn't delivering any value here, it might as well just `return fill`; a composable function that returns a value will still cause its caller to recompose and it's using its own recomposition to change values it returns, not an independently running effect like .collectAsState
or similarAdam Powell
06/22/2021, 5:56 PMremember
it as per @Dominaezzz’s comment you'll realize that you need the actual value to change, and remembering it as-is will mean it just closes over the first calculated value. We don't have a CompositionLocal<T>.currentAsState(): State<T>
that would make putting the actual calculation inside the derivedStateOf {}
block do what you want, but we should probably add it at some point