I have this on my GroupDescriptionActivity class: And in my GroupDescriptionViewModel: I then have a firestore database change listener in the S ...
I have this on my GroupDescriptionActivity class: And in my GroupDescriptionViewModel: I then have a firestore database change listener in the S ...
I'm subscribed to an observable in my Fragment, the observable listens for some user input from three different sources. The main issue is that once ...
I have an editText and a button. When I click on the button the data from the edittext gets inserted into the database. On the save activity I have re ...
I am reading LiveData source code, and for this method: And this is part of its doc: When data changes while the owner is not active, it will n ...
I have a simple room database with LiveData, i want to get (cartPriceI: Double) values by id to use it within specific methods. CartItemsDatabase.kt ...
I am a beginner trying to learn Kotlin by changing an old tutorial to Compose. I have a ViewModel with and Fragment with: How could I adapt thi ...
I have fragment which showing weather for 10 days with getting geolocation city and show exactly weather for this city for 10 days. I have problem in ...
I have single activity android application, a service app with task management. For navigation i use navigation component with bottom navigation. I al ...
I am building a simple weight tracking app in Kotlin, using room, and am having a tough time finding the resource to figure out how to query and retur ...
I have view model and I use live data. Which one is recommended to use and why? In main thread setValue or in IO thread postValue() or in main thread ...
I have view model and I use live data in encapsulation, which one is recommended to use and why? ...
I am trying to observe the LiveData for the method which returns custom pair having 2 values. I want the observable to be triggered when I change eith ...
In sign up fragment, I have term condition part. When you click this text, bottom sheets opens. I click the button that end of the page(Accept Button) ...
I am trying to get LiveData updates in a ViewModel, and make sure that the observer is not leaking, but it is leaking. The typical problem is that the ...
HomeFragment Everything seems to be done correctly, but when you flip the screen, the resulting value from the EditText disappears from the TextView. ...
I am trying to do some stuff on background and then displaying it to the user, but for some reason this does not work as it should and I am not sure w ...
I have a problem with liveData. It doesn't update the fragment with the information. I think it unsubscribes from viewLifecycleOwner at some particula ...
I have a LiveData object (_tracklist) that is making a call to the Dao and retrieves tracks by the songId argument from RoomDB and store it in the Lis ...
Can anyone show me what have I done wrong here, I am using recyclerView with livedata every time I launch the app it spawns with a random list and som ...
I want to run a suspend function in a loop. It is working fine, but postValue is not updating value every time. It calls the observer only once. What ...