I want to enable AndroidX vector support (use app:srcCompat, AppCompatResources.getDrawable) Do I need to enable vectorDrawables.useSupportLibrary if project minSdkVersion > 21?
defaultConfig {
vectorDrawables.useSupportLibrary = true
}
Nick Butcher says that we do need. But I'm in doubt.
Q: Is my understanding correct that this step can be skipped on minSdkVersion=21 and above?
Yes, You can skip this if your minSdkVersion > 21.
This is for minSdkVersion below 21. If you have a vectorDrawable image in your res/drawable, the Gradle plugin will automatically generate raster PNG images for API level 20 and below during build time. This means you only need to update and maintain your vector asset for your app project and Android Studio can take care of image conversion process.