koin-annotations icon indicating copy to clipboard operation
koin-annotations copied to clipboard

KOIN_USE_COMPOSE_VIEWMODEL does not work

Open darriousliu opened this issue 1 year ago • 3 comments
trafficstars

Describe the bug No matter where I add

ksp { 
    arg("KOIN_USE_COMPOSE_VIEWMODEL", "true")
}

, it still import org.koin.androidx.viewmodel.dsl.viewModel

Expected behavior import org.koin.compose.viewmodel.dsl.viewModel

Koin project used and used version (please complete the following information): koin-ksp-compiler 1.4.0-RC3

Additional moduleDefinition Add any other moduleDefinition about the problem here.

darriousliu avatar Jul 27 '24 15:07 darriousliu

Hi @master-lzh , can you try removing the ksp argument? Seems it is deprecated as of version 1.4.*.

kibettheophilus avatar Aug 27 '24 10:08 kibettheophilus

@kibettheophilus The issue is in configuring the code writer for the default module. See fixed #157 .

frogggias avatar Aug 27 '24 10:08 frogggias

@frogggias you are right, hadn't checked the imports well on the generated file.

kibettheophilus avatar Aug 27 '24 11:08 kibettheophilus

yes, did you tried in RC4?

arnaudgiuliani avatar Oct 15 '24 13:10 arnaudgiuliani