Skip to content
This repository has been archived by the owner on Oct 23, 2023. It is now read-only.

Having the issue of installation of vision-camera-code-scanner #137

Open
MarcusCody opened this issue Mar 20, 2023 · 2 comments
Open

Having the issue of installation of vision-camera-code-scanner #137

MarcusCody opened this issue Mar 20, 2023 · 2 comments

Comments

@MarcusCody
Copy link

MarcusCody commented Mar 20, 2023

* What went wrong:
The Android Gradle plugin supports only kotlin-android-extensions Gradle plugin version 1.6.20 and higher.
The following dependencies do not satisfy the required version:
project ':react-native-vision-camera' -> org.jetbrains.kotlin:kotlin-gradle-plugin:1.5.30
    "react": "18.2.0",
    "react-native": "0.71.4",

Tried to add the kotlinVersion ="1.7.0" to the android/build.gradle file but it doesn't work

@Salem-Abderaouf
Copy link

Salem-Abderaouf commented Mar 20, 2023

update build.gradle

    ext {
        RNNKotlinVersion = "1.3.61"
        buildToolsVersion = "30.0.2"
        minSdkVersion = 21
        compileSdkVersion = 31
        targetSdkVersion = 31
        ndkVersion = "22.1.7171670" // install NDk
        kotlinVersion = "1.5.31"
        VisionCameraCodeScanner_targetSdkVersion = 31
        VisionCameraCodeScanner_compileSdkVersion = 31
    }
    repositories {
        google()
        mavenCentral()
    }
    dependencies {
        classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:1.5.31" // kotlin version
        classpath("com.android.tools.build:gradle:4.2.2")
    }

when sdk target is 31 update AndroidManifest.xml

<activity
android:exported="true" // add this
...
>

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants
@Salem-Abderaouf @MarcusCody and others