我想将以前的library
(com.android.library
)更改为feature module
(com.android.dynamic-feature
),但是,当我这样做时,我无法设置targetSdk
或targetSdkVersion
:
plugins {
id("com.android.dynamic-feature")
kotlin("kapt")
kotlin("android")
}
android { // this = DynamicFeatureExtension
compileSdk = BuildConfig.SdkVersion.COMPILE
defaultConfig {
minSdk = BuildConfig.SdkVersion.MIN
targetSdk = BuildConfig.SdkVersion.TARGET // targetSdk is not found
targetSdkVersion(BuildConfig.SdkVersion.TARGET) // targetSdkVersion is not found
...
}
Gradle版本为7.0.2:distributionUrl=https\://services.gradle.org/distributions/gradle-7.0.2-bin.zip
我注意到,当我将它与Plaid App(没有遇到同样的问题)进行比较时,他们的gradle版本是5.6.4。
1条答案
按热度按时间rryofs0p1#
你能试试这个吗?