https://kotlinlang.org logo
Title
v

Vikas Singh

08/26/2021, 5:32 PM
Does coroutine require dependency I have not added any dependency still I am able to access the coroutinescope ?
n

Nick Allen

08/26/2021, 5:44 PM
Yes. If you depend on a library that depends on the coroutine library, then you have the dependency transitively. I'd recommend an explicit dependency just so you can better control the version brought in.
Here's the main one:
dependencies {
    implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-core:1.5.1'
}
There's others for interop with CompleteableFuture, RxJava, Android, and more.
v

Vikas Singh

08/26/2021, 5:51 PM
I have not added any other dependency and all dependencies are using implementation configuration so transitive is not possible
These are the dependencies in the gradle
n

Nick Allen

08/26/2021, 5:59 PM
Try
gradlew :app:dependencies
to see the full dependency tree. (assuming your module is
:app
)
👍 1
v

Vikas Singh

08/26/2021, 6:34 PM
Thanks found it it's with compose ui test