I am making an android app with a few fragments. In one of these fragments, I have a toolbar with a back arrow as an image button.
In the XML File, I have the \"app:srcCompa
add this line to your Gradle file under defaultConfig
block:
vectorDrawables.useSupportLibrary = true
Also, you need to add this block of code in every activity or fragment where you're referencing drawables instead of images in srcCompat
:
static {
AppCompatDelegate.setCompatVectorFromResourcesEnabled(true);
}