-
Notifications
You must be signed in to change notification settings - Fork 0
(MVI) Model View Intent
Devrath edited this page May 30, 2021
·
19 revisions
- To overcome the drawbacks of
MVCcontrolleroverloading with the business logic. Modifications were done to segregate it to a better representation of architecture calledModel-View-Presenter. - It is a relatively new but popular approach to android application architecture.
-
MVPandMVVMare a little bit similar toMVCtoMVI. -
MVPandMVVMhavepresenterandview-modelrespectively to that ofcontrollerforMVC.
Contents |
|---|
MVI specific concepts |
| How the concept of MVI came into existence |
| How MVI works |
| Overview representation of MVI |
| Detailed representation of MVI |
- Uni-directional data flow.
- Immutable state.
- User as a function.
- Its way of simplifying the flow of information which leads to a comprehensive and systematic approach to architecture.
- Many of the advancements in recent times comes from the
web-developmentworld. - Some namely
react,redux,flux, useevent-drivenandfunctionalway of solving things. - They give a unique perspective on how to manage
mutable state. - Such representation fits into
mobile development applications. -
MVIis closely associated withcycle.jsfrom the web development world.
- Much of the code you write in
web developmentisuser focusedinstead ofprocess intensive. -
Architecturein android usually focus on the process instead ofuser. The code gives an interface toaccept inputandsend input. - Place of the
userinmvvmormvpis not transparent. Usually, the user is the kind ofviewin these patterns.