This project is used for tutorials on U4Universe Youtube channel.
As our android app uses MVVM architecture, often times we need to send Commands to our View(Activity) from ViewModel.
We can do this using kotlin enums but there is a limitation with enums. We cannot pass any custom data to View with enums.
Kotlin provide another solution for this ---> SealedClasses
We'll learn
- Create UIState with Sealed Classes
- Send States from ViewModel to Activity
- Update the View according to Ui States
You can contact me if you have any problem related to code or video.
Gmail chsaif369@gmail.com
This repository may contain multiple branches. Each video uses its own branch, so make sure to check the branch used in the video and then select that branch from branch list.
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.