Top "Android-livedata" questions

Android LiveData holds the value and allow it to observe changes and also respects lifecycle of the app components.

Kotlin Flow vs Android LiveData

I have some questions about Kotlin Flow I can observe LiveData from multiple Fragments. Can I do this with Flow? …

android kotlin android-livedata kotlin-coroutines
Forcing Paging Library DataSource refresh

In my ViewModel, I load data using private val pagingConfig = PagedList.Config.Builder() .setEnablePlaceholders(false) .setInitialLoadSizeHint(INITIAL_LOAD_SIZE_HINT) .…

android-architecture-components android-jetpack android-livedata android-paging android-architecture-lifecycle
Cannot find the setter for attribute in Data binding

I am using LiveData, DataBinding, and Kotlin in my application. I defined a Binding Adapter for a RecyclerView like this: …

android data-binding kotlin android-livedata
Convert RxJava Observables To Live Data With Kotlin Extension Functions

I've been using alot of RxJava Observables converted to LiveData in my code using LiveDataReactiveStreams.fromPublisher() library. So I though …

android kotlin rx-java2 android-architecture-components android-livedata
Room - LiveData observer does not trigger when database is updated

I am trying to find out in the code below, why is it that Room's LiveData observable does not give …

android viewmodel android-room android-architecture-components android-livedata
Live Data and 2-Way Data Binding: Custom setter not being called

I am using 2-way data binding to update a LiveData String object from my ViewModel with a string set in …

android data-binding kotlin android-databinding android-livedata
Nullability and LiveData with Kotlin

I want to use LiveData with Kotlin and have values that should not be null. How do you deal with …

android kotlin android-architecture-components android-livedata
How to chain transformations in Android when using live data?

Given the following setup: I have 2 repositories: Repository A and Repository B both of them return live data. I have …

android kotlin android-architecture-components android-livedata
LiveData not updating when data changes

I'm using LiveData to fetch data from a server and observe it. My onChanged() method just gets called the first …

java android android-architecture-components android-livedata android-viewmodel
java.lang.IllegalStateException: Cannot invoke observeForever on a background thread

Can someone help me find where I am going wrong here. I need to continously observer network data and update …

android kotlin android-architecture-components android-workmanager android-livedata