Lifecycle, LiveData, ViewModels - The inner wiring by Florina Muntenescu, Google EN HD
This session was given at Paris Android Makers 2018 by Florina Muntenescu, Google. More info: http://androidmakers.fr/schedule/#session-1 Android Architecture Components is a set of libraries for designing great apps. It contains APIs for implementing concepts like Lifecycle and ViewModel. Whilst these APIs are great, they do come with some questions: • How do Lifecycle, LiveData and ViewModels work under the hood? How and where should each of them be used? • What is the difference between a ViewModel from Architecture Components and the one from the MVVM pattern? • Lifecycle components exist for Activities, Fragments and Application. Why don’t we have the same for Views? • Can we have ViewModels for Views also? • Is LiveData a replacement for RxJava? Can they live side by side? • How does LiveData work with DataBinding? • How should view state be handled and what goes into a Bundle versus a ViewModel? To answer all of these questions and more we’ll do a deep dive in the internals of Lifecycle, LiveData and ViewModels. Alex Karp Production