Ian Warwick
01/30/2020, 2:04 PMModelList
in our models? I found it was the only way to detect changes in a list but not sure if its for use in @Model
annotated classes π€Adam Powell
01/30/2020, 2:08 PMModelList
is for. Alternatively if you're using immutable lists and mutating a reference to said immutable list in a @Model
class, that will also do what you're afterAdam Powell
01/30/2020, 2:10 PM@Model
observation is shallow, it will only make changes to the class annotated with it observable. If you change a plain old mutable object that happens to be held in a val
in an @Model
class, that change won't be tracked.Adam Powell
01/30/2020, 2:12 PM@Model
objects to reference one anotherIan Warwick
01/30/2020, 2:14 PM.frames
package and that seemed a bit low level package for end user πIan Warwick
01/30/2020, 2:18 PMIf you want to detect changes in the content of a mutable list, yes, that's whatCool, can that reference be ais for. Alternatively if you're using immutable lists and mutating a reference to said immutable list in aModelList
class, that will also do what you're after@Model
MutableList
or must it be a ModelList
when mutating the ref?Adam Powell
01/30/2020, 2:19 PMFrameLayout
on some levelAdam Powell
01/30/2020, 2:19 PM@Model
, compose won't know about it unless you tell it explicitlyIan Warwick
01/30/2020, 2:20 PMAdam Powell
01/30/2020, 2:20 PM@Model
(or immutable objects) is going to get very complicated in the presence of some of our multithreading ambitionsIan Warwick
01/30/2020, 2:21 PM@Model
its working super nice! :)