Question; On page 36 you introduce us to the idea of Data Binding. And later on you mention to us that it allows us to stop using the findViewById. statement to get to our individual views. In another course I took we were introduced to View Binding for the same reason.
Can you help me understand what the difference is between Data Binding and View Binding since they seem to do some of the same things?
That’s a very fair question. We do cover view binding in the ABL app that you build in the second half of the book.
Both data binding and view binding are improved way to connect your data and UI. Data binding adds special syntax to reference objects/values in your XML, while view binding gives you typed versions of UI components in your
Fragment code that you can then associate with data.
Both approaches have the same outcome (getting your data to the UI) but take different approaches to do so. Hope this helps!