Android Studio fails to generate databinding after 3.1.0 update

前端 未结 20 2886
爱一瞬间的悲伤
爱一瞬间的悲伤 2020-12-15 02:40

This morning I made an update to android studio from 3.0.1 to 3.1.0. After updating the gradle to latest version I still get build error regarding

相关标签:
20条回答
  • 2020-12-15 03:38

    I was having the same issue. I disabled databinding in gradle properties and it worked. dataBinding.enabled = false

    0 讨论(0)
  • 2020-12-15 03:39

    if you're using kotlin on android studio 3.2 , replace the distributionurl with this line

    distributionUrl=https\://services.gradle.org/distributions/gradle-4.6-all.zip
    

    and you'll be asked to change the build tools version to the apprpriate version. once you've done that , remove this line from the app level build.gradle file

    kapt 'com.android.databinding:compiler:3.0.1
    

    and build the project. it worked for me.

    0 讨论(0)
提交回复
热议问题