gzhenjin
07/22/2021, 9:16 AMMarko Novakovic
07/22/2021, 10:05 AMMVI
is different form the MVVM
not by having UI events streamed to the ViewModel
. Not only that to pre precise. Difference is how state is represented. In MVVM
you generally have multiple streams for different pieces of data. MVI
combines all that into single state class so you only have one state and whole UI is in sync where with MVVM
UI can get out of sync because of multiple streams.
Thats the defining characteristics of MVI
and you can add user events too but that’s optional.gzhenjin
07/22/2021, 1:57 PMMarko Novakovic
07/22/2021, 2:03 PMgzhenjin
07/22/2021, 2:05 PMMarko Novakovic
07/22/2021, 2:59 PMViewModel
and Mavericks
is built on top of Jetpack ViewModel
so it’s actually Jetpack 😄. MVI
was preferred before Compose
and now with Compose
it’s definitely betterHenry
08/20/2021, 1:37 AM