자기계발 공부
React Native Troubleshooting
자기계발도우미
2023. 8. 27. 09:05
npm run android 실행 후 바로 죽을 때
watchman watch-del-all && npm cache clean && cd android && ./gradlew clean && cd ..
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':tasks'.
> Could not create task ':react-native-shared-group-preferences:compileDebugJavaWithJavac'.
> In order to compile Java 9+ source, please set compileSdkVersion to 30 or above
subprojects { subproject ->
afterEvaluate{
if((subproject.plugins.hasPlugin('android') || subproject.plugins.hasPlugin('android-library'))) {
android {
compileSdkVersion rootProject.ext.compileSdkVersion
buildToolsVersion rootProject.ext.buildToolsVersion
}
}
}
}
Uncaught Error : 'app name' has not been registered. This can happen if: ...
위와 같은 에러가 발생한다면 당황하지말고 Metro가 실행되고 있는 터미널을 찾아 종료한 후에 다시 npm run을 해보자