I'm new to Android and a little confused right now.
After setting up a new project with min sdk 21 (Android 5.0) in android studio, by default my main_activity extends AppCompatActivity , which at first was not a problem. I tried to create material. Dark theme as shown here , but @android:style/Theme.Material does not work with AppCompatActivity . Now it works when main_activity simply extends the Activity .
Do I need AppCompatActivity with min sdk 21, if I want to use functions like Action Bar , or is it normal, only from Activity , I thought that AppCompatActivity and v7 Support Libraries exist to support lower sdk in order to be able to use Material Design What am I missing?
If it is not required at sdk level 21 and why, if Android studio set it as the default value, even if value 21 is set as min sdk?
I assume that one of the main questions I have is the best practice of using a material design theme, as described here in conjunction with AppCompatActivity, which Android Studio uses by default.
source share