Android Material Chip Component Crashing App. Unable to Inflate Xml

Android material chip component crashing app. Unable to inflate xml

Update your app theme to inherit from one of these themes:

Theme.MaterialComponents
Theme.MaterialComponents.NoActionBar
Theme.MaterialComponents.Light
Theme.MaterialComponents.Light.NoActionBar
Theme.MaterialComponents.Light.DarkActionBar

For example:

<style name="AppTheme" parent="Theme.MaterialComponents.Light.NoActionBar">

Note: Using a Material Components theme enables a custom view inflater

Source:
https://www.material.io/develop/android/docs/getting-started/

App Crashing with android material Chip Group with material 1.3.0

Replace your AppTheme with this:

<style name="AppTheme" parent="Theme.MaterialComponents.Light.NoActionBar.Bridge">

MaterialCardView crashes with material:1.1.0

you can just keep it in your materialcardview itself also:

 <com.google.android.material.card.MaterialCardView
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:cardCornerRadius="8dp"
**** android:theme="@style/Theme.MaterialComponents.Light" *****
app:cardElevation="8dp">


Related Topics



Leave a reply



Submit