安装code-push后,运行项目出现问题
来源:7-7 FlatList的高级应用&上拉加载更多功能实现-2【这个技能很实用】
哇哦88888888
2019-08-09
请问老师,我安装code-push之后也进行了关联,为什么出现了这样的错误
ERROR: Unable to resolve dependency for ‘:app@releaseStaging/compileClasspath’: Could not resolve project :react-native-code-push.
Show Details
Affected Modules: app
ERROR: Unable to resolve dependency for ‘:app@releaseStagingUnitTest/compileClasspath’: Could not resolve project :react-native-code-push.
Show Details
Affected Modules: app
2回答
-
CrazyCodeBoy
2019-08-12
尝试一下方法进行解决
----
- 删除node_modules;
- npm install重新安装;
- 关闭所有终端;
- 删除APP;
- 重新运行项目;
00 -
哇哦88888888
提问者
2019-08-09
我关联code-push时是用npm link react-native-code-push的,我用rnpm link时出现了错误,错误如下
rnpm-link ERR! ERRPACKAGEJSON No package found. Are you sure it's a React Native project?
(node:10584) UnhandledPromiseRejectionWarning: TypeError: Cannot read property 'replace' of undefined
at Object.projectConfigAndroid [as projectConfig] (D:\nodejs\node_global\node_modules\rnpm\src\config\android\index.js:34:17)
at Object.getProjectConfig (D:\nodejs\node_global\node_modules\rnpm\src\config\index.js:21:22)
at Object.link [as func] (D:\nodejs\node_global\node_modules\rnpm\node_modules\rnpm-plugin-link\src\link.js:99:22)
at Command.runAction (D:\nodejs\node_global\node_modules\rnpm\bin\cli:23:15)
at Command.listener (D:\nodejs\node_global\node_modules\rnpm\node_modules\commander\index.js:315:8)
at Command.emit (events.js:198:13)
at Command.parseArgs (D:\nodejs\node_global\node_modules\rnpm\node_modules\commander\index.js:651:12)
at Command.parse (D:\nodejs\node_global\node_modules\rnpm\node_modules\commander\index.js:474:21)
at Object.<anonymous> (D:\nodejs\node_global\node_modules\rnpm\bin\cli:37:5)
at Module._compile (internal/modules/cjs/loader.js:776:30)
(node:10584) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:10584) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
012019-09-22
相似问题