https://kotlinlang.org logo
#compose
Title
# compose
f

Fabio Beoni

02/24/2024, 5:23 PM
Hi guys... Using compose 1.6.1 I follow the docs about using resources (strings, images, etc) in Compose... Looks like after building the app I should have access to a
Res.*
class, but in my case that is missing. Attaching screenshots from code and configs...
a

Alejandro Rios

02/24/2024, 5:37 PM
You're using the wrong versión (?), the latest one is 1.6.0-rc02, also, you should specify if you're using compose multiplatform or compose android
👍 1
m

Mofe Ejegi

02/24/2024, 6:17 PM
*1.6.0-rc03
f

Fabio Beoni

02/24/2024, 7:34 PM
Sorry guys I don't get it... in semantic versioning 1.6.1 is highier version than 1.6.0-rc*... So it should include changes available in 1.6.0-rc*
a

Alejandro Rios

02/24/2024, 7:36 PM
You're right, but now there's no 1.6.1 version
m

Mofe Ejegi

02/24/2024, 7:36 PM
He's referring to the Compose Plugin version which is the version for Jetbrains's Compose Multiplatform. Yours is set to
1.5.12
The Compose 1.6.1 refers to the AndroidX Jetpack Compose
f

Fabio Beoni

02/24/2024, 7:37 PM
Okay that's interesting since I got the project scaffold from jetbrains compose multiplatform wizard :):)
ok.. got it. many thanks... I am going to try the change
I did the change... now I can find the gradle task
generateComposeResClass
to generate the
Res.*
class... it builds the code but the
Res.
class is still missing 😞
[versions]
agp = "8.2.0" android-compileSdk = "34" android-minSdk = "24" android-targetSdk = "34" androidx-activityCompose = "1.8.2" androidx-appcompat = "1.6.1" androidx-constraintlayout = "2.1.4" androidx-core-ktx = "1.12.0" androidx-espresso-core = "3.5.1" androidx-material = "1.11.0" androidx-test-junit = "1.1.5" compose = "1.6.1" compose-plugin = "1.6.0-rc03" junit = "4.13.2" kotlin = "1.9.22" material3WindowSizeClassAndroid = "1.2.0" window = "1.2.0" [libraries] kotlin-test = { module = "org.jetbrains.kotlin:kotlin-test", version.ref = "kotlin" } kotlin-test-junit = { module = "org.jetbrains.kotlin:kotlin-test-junit", version.ref = "kotlin" } junit = { group = "junit", name = "junit", version.ref = "junit" } androidx-core-ktx = { group = "androidx.core", name = "core-ktx", version.ref = "androidx-core-ktx" } androidx-test-junit = { group = "androidx.test.ext", name = "junit", version.ref = "androidx-test-junit" } androidx-espresso-core = { group = "androidx.test.espresso", name = "espresso-core", version.ref = "androidx-espresso-core" } androidx-appcompat = { group = "androidx.appcompat", name = "appcompat", version.ref = "androidx-appcompat" } androidx-material = { group = "com.google.android.material", name = "material", version.ref = "androidx-material" } androidx-constraintlayout = { group = "androidx.constraintlayout", name = "constraintlayout", version.ref = "androidx-constraintlayout" } androidx-activity-compose = { module = "androidx.activity:activity-compose", version.ref = "androidx-activityCompose" } 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" } androidx-window = { group = "androidx.window", name = "window", version.ref = "window" } [plugins] androidApplication = { id = "com.android.application", version.ref = "agp" } androidLibrary = { id = "com.android.library", version.ref = "agp" } jetbrainsCompose = { id = "org.jetbrains.compose", version.ref = "compose-plugin" } kotlinMultiplatform = { id = "org.jetbrains.kotlin.multiplatform", version.ref = "kotlin" }
2 Views