[英]When I create a new project in Android Studio, which API level should I choose according to project type as the minimum SDK?
For example, for which project content should I choose API 21:Android 5.0(Lollipop)?例如,我应该为哪个项目内容选择 API 21:Android 5.0(Lollipop)? Or for which project content should I choose API 16:Android 4.1(Jelly Bean)?
或者我应该为哪个项目内容选择 API 16:Android 4.1(Jelly Bean)? etc. In short, what should we consider when choosing API levels in Android Studio?
等等。简而言之,在Android Studio中选择API关卡应该考虑什么? API Levels
API 级别
It depends on the project, and the api's you will use like there is some libraries that doesn't support old api levels like 16 and below, so first choose low api like 16(Android 4.1) then if u include some api's that needs higher minimum sdk you can increase it from (build.gradle):这取决于项目,您将使用的 api 就像有些库不支持旧的 api 级别(如 16 及以下),所以首先选择低 api 像 16(Android 4.1)然后如果您包含一些需要更高级别的 api最低 sdk 你可以从(build.gradle)增加它:
defaultConfig {
applicationId "Your app package"
//this is the minimum sdk
minSdkVersion 21
targetSdkVersion 30
versionCode 1
versionName "1.0"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.