Help me! ViewModel

This is an architecture explanation session for those who want to use Compose, those who want to learn the latest app design, or those who want to focus on development when working in a team. I will explain the best design know-how for the Compose era, combining the modern UI framework Compose and ViewModel. Every Android app developer probably experienced the same hesitations regarding the design and implementation principles of ViewModel. When you first come into contact with it, or when discussing design principles with your team, ViewModel is often at the center of the discussion. In this session, I will introduce practices that you should definitely keep in mind, based on questions and knowledge gathered from the community, and from my experience developing Full-Compose apps. I will present the standards of this new era, with the aim of solving the following situations that are particularly easy to fall into. - Situations where you wonder "What is the best practice to handle this?" because you are unfamiliar with the matter - Common mistakes, such as reaching a point after trial and error where you think "I thought this implementation was good, but in hindsight, that other way was better." The example source codes will be borrowed from Google's Compose sample, to facilitate an understanding within the context of a code base. Then in the second half, I will go further to support you, by going over how to deal with and think about the complexities of applications that have complicated UI specifications, business requirements, and multiple ViewModels. Through these, I will provide you all the know-how you need for design but can’t be obtained by reading the official guidelines, for example how to interpret the recommended architecture. Planned content for the session (subject to change) - ViewModel responsibilities and app design basics - Criteria for dividing ViewModel and UI View responsibilities - Understanding ViewModel and UI initialization - UIState and logic in the Compose era - Error handling and business logic in ViewModel - ViewModel testing strategy (Translated by the DroidKaigi Committee)

  • mhidaka Software Engineer, Representative of TechBookFest


Summary

  • Dates 2024.09.12 / 14:20 ~ 15:00 (40min)
  • Place Iguana
  • Language Japanese (English interpretation available)

Intended audience

- Beginners in app development - People who want to use or have just started using Compose - People who want to learn or create design guidelines for team development This session has a broad range of targets, from beginners in app development, to professional users, and those who work in a team, and does not require any special knowledge of the Compose framework.

Android is a trademark of Google LLC. The Android robot is reproduced or modified from work created and shared by Google and used according to terms described in the Creative Commons 3.0 Attribution License. Android, Google Play and the Google Play logo are trademarks of Google LLC.
Past DroidKaigi

© 2014- DroidKaigi Committee