Skip to content

Commit e046977

Browse files
authored
Merge pull request #192 from joreilly/dep_updates
dependency updates/cleanup
2 parents 34ac90f + 46e250f commit e046977

File tree

18 files changed

+609
-1348
lines changed

18 files changed

+609
-1348
lines changed

.graphqlconfig

Lines changed: 0 additions & 15 deletions
This file was deleted.

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# StarWars
22

3-
![kotlin-version](https://img.shields.io/badge/kotlin-2.1.0-blue?logo=kotlin)
3+
![kotlin-version](https://img.shields.io/badge/kotlin-2.2.0-blue?logo=kotlin)
44

55
Minimal GraphQL based Jetpack Compose, Wear Compose and SwiftUI Kotlin Multiplatform sample (using StarWars endpoint - https://graphql.org/swapi-graphql).
66
Makes use of [Apollo](https://github.com/apollographql/apollo-android) library and in particular

androidApp/build.gradle.kts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
2+
13
plugins {
24
id("com.android.application")
35
kotlin("android")
@@ -49,7 +51,6 @@ dependencies {
4951
implementation(libs.androidx.compose.ui)
5052
implementation(libs.androidx.compose.ui.tooling)
5153
implementation(libs.androidx.navigation.compose)
52-
implementation(libs.accompanist.insets)
5354
implementation(libs.androidx.compose.material3)
5455

5556
implementation(libs.koin.core)
@@ -65,6 +66,6 @@ dependencies {
6566
}
6667

6768
tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile>().configureEach {
68-
kotlinOptions.jvmTarget = "17"
69+
compilerOptions.jvmTarget.set(JvmTarget.JVM_17)
6970
}
7071

androidApp/src/androidTest/java/dev/johnoreilly/starwars/androidApp/StarWarsUITest.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ class StarWarsUITest {
2727
people.forEachIndexed { index, person ->
2828
val rowNode = personListNode.onChildAt(index).onChild()
2929
rowNode.assertTextContains(person.name)
30-
rowNode.assertTextContains(person.homeworld.name)
30+
rowNode.assertTextContains(person.homeworld?.name ?: "")
3131
}
3232
}
3333

androidApp/src/main/java/dev/johnoreilly/starwars/androidApp/MainActivity.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,7 @@ fun PersonView(person: PersonFragment) {
167167
},
168168
supportingContent = {
169169
Text(
170-
person.homeworld.name,
170+
person.homeworld?.name ?: "",
171171
style = MaterialTheme.typography.titleMedium,
172172
color = Color.DarkGray
173173
)

compose-web/build.gradle.kts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ version = "1.0-SNAPSHOT"
1212
@OptIn(org.jetbrains.compose.ExperimentalComposeLibrary::class)
1313
kotlin {
1414
wasmJs {
15-
moduleName = "StarWars"
1615
browser {
1716
commonWebpackConfig {
1817
outputFileName = "StarWars.js"

gradle/libs.versions.toml

Lines changed: 20 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,30 @@
11
[versions]
2-
kotlin = "2.1.0"
3-
ksp = "2.1.0-1.0.29"
4-
kotlinx-coroutines = "1.9.0"
5-
6-
androidGradlePlugin = "8.7.3"
7-
koin = "4.0.0"
8-
koinComposeMultiplatform = "4.0.0"
9-
apollo = "4.1.0"
10-
apolloMockServer = "0.1.0"
11-
kmpNativeCoroutines = "1.0.0-ALPHA-38"
12-
13-
androidxActivity = "1.9.3"
14-
androidxComposeBom = "2024.12.01"
15-
androidx-navigation = "2.8.0-alpha08"
16-
androidx-lifecycle = "2.8.4"
17-
accompanist = "0.30.1"
18-
horologist = "0.6.20"
19-
wearCompose = "1.4.0"
20-
composeMultiplatform = "1.7.3"
2+
kotlin = "2.2.0"
3+
ksp = "2.1.21-2.0.1"
4+
kotlinx-coroutines = "1.10.2"
5+
6+
androidGradlePlugin = "8.11.0"
7+
koin = "4.1.0"
8+
koinComposeMultiplatform = "4.1.0"
9+
apollo = "4.3.1"
10+
apolloMockServer = "0.1.1"
11+
kmpNativeCoroutines = "1.0.0-ALPHA-45"
12+
13+
androidxActivity = "1.10.1"
14+
androidxComposeBom = "2025.06.01"
15+
androidx-navigation = "2.8.0-alpha13"
16+
androidx-lifecycle = "2.9.1"
17+
horologist = "0.6.23"
18+
wearCompose = "1.4.1"
19+
composeMultiplatform = "1.8.2"
2120
composeWindowSize = "0.5.0"
2221

2322
junit = "4.13.2"
2423

2524
minSdk = "24"
2625
minWearSdk = "28"
27-
targetSdk = "34"
28-
compileSdk = "34"
26+
targetSdk = "35"
27+
compileSdk = "35"
2928

3029

3130

@@ -50,10 +49,6 @@ androidx-compose-material3 = { group = "androidx.compose.material3", name = "mat
5049
androidx-lifecycle-viewmodel-compose = { module = "org.jetbrains.androidx.lifecycle:lifecycle-viewmodel-compose", version.ref = "androidx-lifecycle" }
5150
androidx-navigation-compose = { module = "org.jetbrains.androidx.navigation:navigation-compose", version.ref = "androidx-navigation" }
5251

53-
accompanist-insets = { group = "com.google.accompanist", name = "accompanist-insets", version.ref = "accompanist" }
54-
accompanist-pager = { group = "com.google.accompanist", name = "accompanist-pager", version.ref = "accompanist" }
55-
accompanist-pagerIndicator = { group = "com.google.accompanist", name = "accompanist-pager-indicators", version.ref = "accompanist" }
56-
5752
androidx-wear-compose-foundation = { module = "androidx.wear.compose:compose-foundation", version.ref = "wearCompose" }
5853
androidx-wear-compose-material = { module = "androidx.wear.compose:compose-material", version.ref = "wearCompose" }
5954
androidx-wear-compose-navigation = { module = "androidx.wear.compose:compose-navigation", version.ref = "wearCompose" }

gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-8.9-bin.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.13-bin.zip
44
networkTimeout=10000
55
validateDistributionUrl=true
66
zipStoreBase=GRADLE_USER_HOME

iosApp/iosApp/ContentView.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ struct PersonView: View {
4242
var body: some View {
4343
VStack(alignment: .leading) {
4444
Text(person.name).font(.headline)
45-
Text(person.homeworld.name).font(.subheadline)
45+
Text(person.homeworld?.name ?? "").font(.subheadline)
4646
}
4747
}
4848
}

shared/build.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ apollo {
8080
generateSchema.set(true)
8181
generateDataBuilders.set(true)
8282
introspection {
83-
endpointUrl.set("https://swapi-graphql.netlify.app/.netlify/functions/index")
83+
endpointUrl.set("https://swapi-graphql.netlify.app/graphql")
8484
schemaFile.set(file("src/commonMain/graphql/schema.graphqls"))
8585
}
8686
}

0 commit comments

Comments
 (0)