Code QuizBeginner

Applying a Material theme to the app

Learn how to correctly apply a Material Components theme in your app's manifest and styles.

Codexml
<!-- res/values/themes.xml -->
<resources>
    <style name="Theme.MyApp" parent="Theme.AppCompat.Light.DarkActionBar">
        <item name="colorPrimary">@color/purple_500</item>
        <item name="colorSecondary">@color/teal_200</item>
    </style>
</resources>

<!-- AndroidManifest.xml -->
<application
    android:theme="@style/Theme.MyApp">
</application>

What is the bug that prevents Material Components (like MaterialButton) from working correctly?