Issue
I have been doing it in Android studio for a few days but I have never had such a problem :(
Background blank only text showing androidx.constraintlayout....ConstraintLayout
XML file
<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/container"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:paddingTop="?attr/actionBarSize">
</androidx.constraintlayout.widget.ConstraintLayout>
Gradle file
dependencies {
implementation 'androidx.appcompat:appcompat:1.4.1'
implementation 'com.google.android.material:material:1.5.0'
implementation 'androidx.constraintlayout:constraintlayout:2.1.3'
implementation 'androidx.lifecycle:lifecycle-livedata-ktx:2.4.0'
implementation 'androidx.lifecycle:lifecycle-viewmodel-ktx:2.4.0'
implementation 'androidx.navigation:navigation-fragment:2.4.0'
implementation 'androidx.navigation:navigation-ui:2.4.0'
testImplementation 'junit:junit:4.+'
androidTestImplementation 'androidx.test.ext:junit:1.1.3'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.4.0'
}
Solution
Update your Constraintlayout
dependency in your app level build.gradle
and check:
implementation 'androidx.constraintlayout:constraintlayout:2.1.3'
Answered By - Shailendra Madda
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.