点击打开链接
在AndroidStudio更新到3.0之后发现上面的配置不能用了,这里记录下解决方法
- 首先把项目下的build.gradle中的classpath ‘com.neenbedankt.gradle.plugins:android-apt:1.8’删掉
- 把module下面的build.gradle最上面引入的插件删掉,不管是下面这两个中的哪一个,都删掉
- apply plugin: ‘com.neenbedankt.android-apt’
- apply plugin: ‘android-apt
-
在module下的build.gradle中的依赖修改为
- 1
- 2
- 3
- 4
经过这三步就可以了