Approaching Android with MVVM
Joe Birch
1K21

Very good article! Thanks!
Just one thing for you to consider. You say that: “For me, this is where Data Binding could have a negative effect on its usage. This is moving a Views display logic into the View itself.”. But that is actually how it should be :) You should have the ViewModel expose a data property and then utilize a binding converter (pure function) to convert the value of that property into a View.Visible/View.Gone value. That way, the ViewModel doesn’t know anything about display logic, and View doesn’t have to care about how it obtains the resulting value. Basically, it’s like adding a very thin layer between the ViewModel and View. This is also the way MVVM in WPF works.

One clap, two clap, three clap, forty?

By clapping more or less, you can signal to us which stories really stand out.