Error:All flavors must now belong to a named flavor dimension.
Posted lifan1998
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Error:All flavors must now belong to a named flavor dimension.相关的知识,希望对你有一定的参考价值。
环境
android studio 3.0
错误
Error:All flavors must now belong to a named flavor dimension.
解决
在build.gradle中
android.defaultConfig 添加flavorDimensions "versionCode"
例如·:
android {
compileSdkVersion rootProject.ext.compileSdkVersion
buildToolsVersion rootProject.ext.buildToolsVersion
defaultConfig {
minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion
versionCode rootProject.ext.versionCode
versionName rootProject.ext.versionName
flavorDimensions "versionCode"
}
...
以上是关于Error:All flavors must now belong to a named flavor dimension.的主要内容,如果未能解决你的问题,请参考以下文章
web性能优化之:no-cache与must-revalidate深入探究
web 性能优化之:no-cache 与 must-revalidate 深入探究
max-age, no-Cache,must-revalidate on Cache-Control Header,这里优先考虑哪个?
no-cache 和 must-revalidate 之间的区别