https://kotlinlang.org logo
#compose
Title
# compose
t

Timo Drick

12/17/2019, 1:16 AM
When i write following class:
Copy code
@Model
Test(var test: String)
the Compose framework will observe it and recompose the UI when it changes. Can i also observe this class in my custom code outside of a @Composable function?
👍 1
a

Adam Powell

12/17/2019, 2:17 AM
Yes, though the API is pretty raw right now. Take a look at
Frames.kt
for some of the low-level details
a

Andrey Kulikov

12/17/2019, 12:37 PM
💯 1
👍 1
t

Timo Drick

12/17/2019, 3:32 PM
Ok thx Andrey that looks good. Unfortunately i currently working with the 0.1.0-dev03 version. Maybe i will change to the dev branch because i also see other things working better on dev (e.g. animation)