I've recently been experimenting with using the An...
# feed
r
I've recently been experimenting with using the AndroidX Jetpack ViewModels and DataStore in a KMP app with SwiftUI/Jetpack Compose native views, and I wrote an article to document this. I hope this helps, any feedback is welcome. https://appmilla.com/latest/getting-started-with-jetpack-viewmodels-and-datastore-in-kotlin-multiplatform/
🚀 4
💯 4
👍🏾 1
👍 1
s
looks good.... a small improvement would be to enforce unidirectional data flow in the VM... both the repository and timer function can update the timer as it is now...
r
@stojan Thanks for the observation. I was more focused on the lifecycle aspects of the ViewModel integration, so I didn't really consider that. If I get time, I'll update the code.
👍 1