What is an efficient way of returning values in viewmodel scopes / function scopes in kotlin
I have a QuestDetailScreen in which I call getDailyQById(id), which passes to a viewmodel -> repo -> dao -> database. I use LiveData in the viewmodel for the DailyQuest vals. To not have the database call be on the main thread, I surrounded the repo call in a viewModelScope. But when this returns to the view in QuestDetailScreen it also has to be in a scope for me to access it.
I would like to access the DailyQuest that has been returned to be accessible outside of this scope....