Skip to content

Commit

Permalink
Move dependencies to Gradle version catalog (#27)
Browse files Browse the repository at this point in the history
  • Loading branch information
krzema12 authored Oct 17, 2024
1 parent c67a8ad commit 0f0d26f
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 6 deletions.
10 changes: 5 additions & 5 deletions composeApp/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ plugins {
alias(libs.plugins.kotlinMultiplatform)
alias(libs.plugins.composeCompiler)
alias(libs.plugins.jetbrainsCompose)
kotlin("plugin.serialization") version "2.0.21"
alias(libs.plugins.kotlinxSerialization)
}

kotlin {
Expand All @@ -32,15 +32,15 @@ kotlin {
sourceSets {
val wasmJsMain by getting {
dependencies {
implementation("io.ktor:ktor-client-js:3.2.0")
implementation(libs.ktor.client.js)
}
}

val desktopMain by getting {
dependencies {
implementation(compose.desktop.currentOs)
implementation(libs.kotlinx.coroutines.swing)
implementation("io.ktor:ktor-client-cio:3.0.0")
implementation(libs.ktor.client.cio)
}
}

Expand All @@ -51,8 +51,8 @@ kotlin {
implementation(compose.ui)
implementation(compose.components.resources)
implementation(compose.components.uiToolingPreview)
implementation("io.ktor:ktor-client-core:3.2.0")
implementation("com.charleskorn.kaml:kaml:0.61.0")
implementation(libs.ktor.client.core)
implementation(libs.kaml)
}
}
}
Expand Down
10 changes: 9 additions & 1 deletion gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ compose-plugin = "1.7.0"
junit = "4.13.2"
kotlin = "2.0.21"
kotlinx-coroutines = "1.9.0"
ktor = "3.0.0"
kaml = "0.61.0"

[libraries]
kotlin-test = { module = "org.jetbrains.kotlin:kotlin-test", version.ref = "kotlin" }
Expand All @@ -12,8 +14,14 @@ junit = { group = "junit", name = "junit", version.ref = "junit" }
compose-ui-tooling = { module = "androidx.compose.ui:ui-tooling", version.ref = "compose" }
compose-ui-tooling-preview = { module = "androidx.compose.ui:ui-tooling-preview", version.ref = "compose" }
kotlinx-coroutines-swing = { group = "org.jetbrains.kotlinx", name = "kotlinx-coroutines-swing", version.ref = "kotlinx-coroutines" }
ktor-client-core = { group = "io.ktor", name = "ktor-client-core", version.ref = "ktor" }
ktor-client-js = { group = "io.ktor", name = "ktor-client-js", version.ref = "ktor" }
ktor-client-cio = { group = "io.ktor", name = "ktor-client-cio", version.ref = "ktor" }
kaml = { group = "com.charleskorn.kaml", name = "kaml", version.ref = "kaml" }

[plugins]
jetbrainsCompose = { id = "org.jetbrains.compose", version.ref = "compose-plugin" }
composeCompiler = { id = "org.jetbrains.kotlin.plugin.compose", version.ref = "kotlin" }
kotlinMultiplatform = { id = "org.jetbrains.kotlin.multiplatform", version.ref = "kotlin" }
kotlinMultiplatform = { id = "org.jetbrains.kotlin.multiplatform", version.ref = "kotlin" }
kotlinxSerialization = { id = "org.jetbrains.kotlin.plugin.serialization", version.ref = "kotlin" }

0 comments on commit 0f0d26f

Please sign in to comment.