首页 > 解决方案 > [反应原生][ios] 'MODULE_NOT_FOUND',@react-native-community/cli

问题描述

在 ios 文件夹上执行命令“pod install”时,我遇到 react-native-community/cli 问题

如何解决这些问题?

【我的 react native 项目包版本】“@react-native-community/cli”:“6.1.0”,“react”:“17.0.2”,“react-native”:“0.66.0”

[版本] xcode:12.5.1 节点:16.11.0 cocoapods:1.11.2

错误代码

Debugger attached.
Waiting for the debugger to disconnect...'
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:885:15)
    at Function.Module._load (internal/modules/cjs/loader.js:730:27)
    at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:72:12)
    at internal/main/run_main_module.js:17:47 {
  code: 'MODULE_NOT_FOUND',
  requireStack: []
}

[!] Invalid `Podfile` file: 767: unexpected token at ''.

 #  from /Users/limminyeong/Desktop/yun/3_기타/react_native_test/AwesomeProject/ios/Podfile:7
 #  -------------------------------------------
 #  target 'AwesomeProject' do
 >    config = use_native_modules!
 #  
 #  -------------------------------------------```

**error code img**
[enter image description here][1]


  [1]: https://i.stack.imgur.com/LYRdP.png

标签: iosreact-nativereact-native-community

解决方案


推荐阅读