compose-multiplatform
compose-multiplatform copied to clipboard
1.2.0-alpha01-dev748 breaks androidx.compose.foundation.lazy.grid
With the following setup:
const val kotlin = "1.7.10"
const val desktop = "1.2.0-alpha01-dev748"
const val core = "1.2.0-rc03"
const val compiler = "1.3.0-beta01"
allprojects {
repositories {
google()
mavenCentral()
maven(url = "https://maven.pkg.jetbrains.space/public/p/compose/dev")
}
configurations.all {
resolutionStrategy.dependencySubstitution {
substitute(module("org.jetbrains.compose.compiler:compiler")).apply {
using(module("androidx.compose.compiler:compiler:${Versions.Android.Compose.compiler}"))
}
}
}
}
I’m testing 1.2.0-alpha01-dev748 and I’m having problems importing androidx.compose.foundation.lazy.grid.
With version 1.0.1 I was using:
import androidx.compose.foundation.lazy.GridCells
import androidx.compose.foundation.lazy.LazyVerticalGrid
With version 1.2.0-alpha01-dev748 I had to change to:
import androidx.compose.foundation.lazy.grid.LazyVerticalGrid
import androidx.compose.foundation.lazy.grid.GridCells
Otherwise the IDE throws an error. Up on changing, the IDE doesn’t complain and find the classes, but when I try to build I get the following:
> Task :shared-ui-compose:compileDebugKotlinAndroid FAILED
Unresolved reference: grid
Unresolved reference: grid
Unresolved reference: LazyVerticalGrid
Unresolved reference: GridCells
Unresolved reference: item
@Composable invocations can only happen from the context of a @Composable function
@Composable invocations can only happen from the context of a @Composable function
shared-ui-compose it's a module to share composables between Desktop and Android.
What’s missing? 🤔