1. The purpose of this post
I would demo how to solve this error when using android studio
- Android Studio 3.x
- gradle wrapper version:
- project build.gradle
- classpath ‘com.android.tools.build:gradle:3.5.0’
3. Solution and Code
Because some features need java 8 support,just add this compile options in the app’s build.gradle
You can get more info about android and java8 support by this official document.
Clean,rebuild and run the app, everything works.