Skip to content

Commit 6cca463

Browse files
committed
Add note about IDE issues
1 parent 5cc9cde commit 6cca463

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

KSP/README.md

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,11 @@ kotlin {
2929
androidTarget()
3030
iosX64()
3131
//...
32+
33+
//Might need to add this if you cannot see generated code in your IDE
34+
sourceSets.named("commonMain").configure {
35+
kotlin.srcDir("build/generated/ksp/metadata/commonMain/kotlin")
36+
}
3237
}
3338

3439
dependencies {
@@ -38,4 +43,12 @@ dependencies {
3843
add("kspJvm", "io.github.jan-tennert.supabase:ksp-compiler:VERSION")
3944
add("kspAndroid", "io.github.jan-tennert.supabase:ksp-compiler:VERSION")
4045
add("kspIosX64", "io.github.jan-tennert.supabase:ksp-compiler:VERSION")
41-
}
46+
}
47+
48+
//Might need to add this if you cannot see generated code in your IDE
49+
project.tasks.withType(KotlinCompilationTask::class.java).configureEach {
50+
if(name != "kspCommonMainKotlinMetadata") {
51+
dependsOn("kspCommonMainKotlinMetadata")
52+
}
53+
}
54+
```

0 commit comments

Comments
 (0)