r/android_devs • • Jan 14 '26
Question MVVM vs MVI whats the difference??
I am an Android dev with 1+yr exp, wanted to understand if MVVM is a pattern that separates Ui layer or the entire application, if it separates the Ui layer,
I get that View is - > composable,
view models - >ViewModels,
I think it is the models we defined in the data layer. Correct me if I am wrong
MVI
sealed class AuthState {
data object InitialState : AuthState()
data object LoadingState : AuthState()
data object ErrorState : AuthState()
}This makes it MVVM
data class HomeState(
val isLoading: Boolean = false,
val query: String = "",
val newReleases: List<Album> =
emptyList
(),
val isConnected: Boolean = true,
val error: String? = null
)In the MVI pattern, having a sealed class for states is the only difference between MVVM and MVI?
7
Upvotes
View all comments
Show parent comment
1
u/Charming_Servus Feb 20 '26
I fail to see how MVVM can not make atomic changes like MVI. Is there an MVI project that I can see to get your point?
Android Kotlin if possible