robstoll
08/11/2021, 3:26 PMjendrik
08/14/2021, 6:30 PMdependencies { }
inside a Kotlin target block does not support constraints. That’s something the Kotlin plugin adds (not part of Gradle core).
But the mechanism is only an alternative to Gradle’s core dependency declaration mechanism.
You can use that instead to define dependencies and constraints.
Basically:
kotlin.sourceSets.commonMain.dependencies.implementation
is the same as:
dependencies.commonMainImplementation
dependencies {
commonMainImplementation("...") // <-- dependency
constraints {
commonMainImplementation("...") // <-- dependency constraints
}
}
robstoll
08/14/2021, 6:50 PM