当我运行react-native run-android
时,我会得到以下错误:
react-native run-android
, I get the following error:FAILURE: Build failed with an exception.
* What went wrong:
A problem occurred configuring project ':app'.
> Could not resolve all dependencies for configuration ':app:_debugApk'.
> Configuration with name 'default' not found.
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
我知道这意味着存在一些链接错误,但我想不出是什么。我希望能得到修复的帮助,因为我还很新于Android开发。
react-native unlink
没有完全卸载一个包。它在MainApplication.java
中留下了一行代码。我已经卸载了 npm 包,所以它试图在一个不存在的目录中查找某些东西。所以我只需要手动从MainApplication.java
中删除这些行即可。 - Noitidart