반응형
React-Native에서 카메라 기능을 사용하기 위해서
react-native-camera-kit를 설치 후
아래와 같은 오류 발생
Build failed with 2 errors
react-native-camera-kit/android/build.gradle' line: 2
Plugin with id 'kotlin-android' not found.
환경 : project react-native version 0.69.1

- 해결 방법 -
1. /android/build.gradle에
kotlin_version 설정
buildscript {
ext {
...
kotlin_version = '1.5.10'
}
2. buildscript.repositories와 allprojects.repositories에
google() 설정
buildscript {
repositories {
...
google()
}
}
allprojects {
repositories {
...
google()
}
}
3. buildscript.dependencies에
kotlin classpath 설정
dependencies {
...
classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version")
}
4. /android/app/build.gradle에
kotlin import
apply plugin: "kotlin-android"
apply plugin: "kotlin-android-extensions"
5. minSdkVersion 변경
buildscript {
ext {
...
minSdkVersion = 23 // 23으로 변경
}
해당 내용으로 고생하다가 github에서 관련 내용을
찾아서 정리 및 공유차 작성하였습니다.
원본글은 아래에서 확인 가능합니다.
https://github.com/teslamotors/react-native-camera-kit/issues/475
반응형
'Programing > React-Native' 카테고리의 다른 글
[React-Native] 안드로이드 기본 텍스트 색상 지정하기 Android default font color (0) | 2022.08.09 |
---|---|
[React-Native] Unable to load script. Make sure you're either running Metro 오류 (1) | 2022.08.09 |
댓글