https://kotlinlang.org logo
#korge
Title
# korge
a

andylamax

06/17/2020, 2:19 AM
how do I add dependencies to korge using gradle? Problem: Korge targets all platforms, android, jvm, native and js. I just wan't to target android, jvm and js alone. how do I add my multiplatform dependencies without providing the native implementations? Some of these dependencies are 3rd party. Is there a way I can configure the korge gradle plugin?
a

arnis71

06/17/2020, 3:55 AM
You can add dependencies in build.gradle with dependencies {} block. See example https://www.github.com/korlibs/korge-samples/tree/master/video%2Fbuild.gradle.kts
For supporting the specific targets I think it is not supported yet. You should create the issue on GitHub for that. I would +1 it.
a

andylamax

06/17/2020, 7:43 AM
Thank you for your response.
👍 1
t

tobsef

06/17/2020, 2:26 PM
During the jam I also tried to add a dependency... the https://github.com/Kotlin/kotlinx.serialization which is already a multiplatform project. But I also wasn't able to get it work.
d

Deactivated User

06/17/2020, 7:01 PM
mmo-poc is using korge, kotlinx.serialization and ktor
a

arnis71

06/18/2020, 3:59 AM
@tobsef that's weird. I made it work. Did you declare the dependency like in the example? Also don't forget to include all 4 dependencies for common, jvm, J's and native.
8 Views