Android Kotlin LiveDataReactiveStreams unresolved reference

mobiledev

New member
Apr 7, 2023
2
0
1
Visit site
Hello, if I include the following code in build.gradle;
implementation("androidx.activity:activity-compose:1.8.2")
I get the following error when I build the app;
Unresolved reference: LiveDataReactiveStreams
if I remove it then the app compiles. I import LiveDataReactiveStreams in kotlin code using;
import androidx.lifecycle.LiveDataReactiveStreams
Usage is as follows;
disposable = Flowable.zip<Resource<ServicesModel>, Resource<MyModel>,
Pair<Resource<ServicesModel>, Resource<MyModel>>>(
LiveDataReactiveStreams.toPublisher(this, servicesViewModel.getServices()),
LiveDataReactiveStreams.toPublisher(
this,
optionsViewModel.getOptions()
)
) { services, options ->
Pair(services, options)
}.doOnError {
binding.progressBar.hideProgressBar(activity)
}.observeOn(AndroidSchedulers.mainThread())
.subscribeOn(Schedulers.computation()).subscribe { (services, options) ->
setServiceListDataFromResponse(services, options)
}
Does anyone know what is happening here?
 
Last edited:

B. Diddy

Senior Ambassador
Moderator
Mar 9, 2012
165,967
5,280
113
Visit site
Welcome to Android Central! I moved this to the Software Development forum for more specific traffic.
 

Members online

Forum statistics

Threads
944,531
Messages
6,923,244
Members
3,159,608
Latest member
nasrulawal026