From de7757d64c4a80c4a38c65da265e228b34c09a95 Mon Sep 17 00:00:00 2001 From: Vinicius Sossella Date: Thu, 7 Oct 2021 16:07:42 -0300 Subject: [PATCH] added desugaring feature --- android/build.gradle | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/android/build.gradle b/android/build.gradle index b329686..b5f8a4c 100644 --- a/android/build.gradle +++ b/android/build.gradle @@ -34,11 +34,18 @@ android { // minSdkVersion is determined by Native View. minSdkVersion 20 testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" + multiDexEnabled true } buildFeatures { viewBinding = true } - + compileOptions { + // Flag to enable support for the new language APIs + coreLibraryDesugaringEnabled true + // Sets Java compatibility to Java 8 + sourceCompatibility JavaVersion.VERSION_1_8 + targetCompatibility JavaVersion.VERSION_1_8 + } } dependencies { @@ -46,4 +53,5 @@ dependencies { implementation('com.journeyapps:zxing-android-embedded:4.1.0') { transitive = false } implementation 'androidx.appcompat:appcompat:1.3.0' implementation 'com.google.zxing:core:3.4.1' + coreLibraryDesugaring 'com.android.tools:desugar_jdk_libs:1.1.5' }