简体   繁体   English

React Native中缺少依赖项

[英]Missing dependency in React Native

I'm trying to build an app for Android but have been getting this error all afternoon: 我正在尝试为Android构建应用程序,但整个下午都收到此错误消息:

A problem occurred configuring project ':app'.
> Could not resolve all dependencies for configuration ':app:_debugApk'.
   > Configuration with name 'default' not found.

Just need to run some updates, I would think. 我想,只需要运行一些更新即可。 So from the app's root I have tried: 因此,从应用程序的根源开始,我尝试过:

yarn

and then 接着

npm i

and

cup all -y

But the problem persists. 但是问题仍然存在。

settings.gradle: settings.gradle:

rootProject.name = 'MyAppName'

include ':react-native-firestack'
project(':react-native-firestack').projectDir = new File(rootProject.projectDir, './node_modules/:react-native-firestack/android/')

include ':react-native-fbsdk'
project(':react-native-fbsdk').projectDir = new File(rootProject.projectDir, './node_modules/:react-native-fbsdk/android/')

include ':app'

在安装react-native-fbsdk之后是否运行了此命令( react-native run-android )?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM