Warning: file_get_contents(/data/phpspider/zhask/data//catemap/0/react-native/7.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Reactjs 反应本机:错误:无法解析模块'SegmentedControlIOS`_Reactjs_React Native_Xcode10 - Fatal编程技术网

Reactjs 反应本机:错误:无法解析模块'SegmentedControlIOS`

Reactjs 反应本机:错误:无法解析模块'SegmentedControlIOS`,reactjs,react-native,xcode10,Reactjs,React Native,Xcode10,当我更新到xCode10时,我遇到了一个严重的错误。错误是这样说的 error: bundling failed: Error: Unable to resolve module `SegmentedControlIOS` from `/node_modules/react-native/Libraries/react-native/react-native-implementation.js`: Module does not exist in the module map This mig

当我更新到xCode10时,我遇到了一个严重的错误。错误是这样说的

error: bundling failed: Error: Unable to resolve module `SegmentedControlIOS` from `/node_modules/react-native/Libraries/react-native/react-native-implementation.js`: Module does not exist in the module map

This might be related to https://github.com/facebook/react-native/issues/4968
To resolve try the following:
  1. Clear watchman watches: `watchman watch-del-all`.
  2. Delete the `node_modules` folder: `rm -rf node_modules && npm install`.
  3. Reset Metro Bundler cache: `rm -rf /tmp/metro-bundler-cache-*` or `npm start -- --reset-cache`.  4. Remove haste cache: `rm -rf /tmp/haste-map-react-native-packager-*`.
我正在使用以下版本的react ana babel:

“巴别塔预设反应本机”:“4.0.0”, “反应本机”:“0.54.0”

我试图重新安装节点模块。但它不起作用

如果有人有相同的问题并能够解决,请告诉我

谢谢

重置缓存 照常
它每次都像一个符咒

你能让它工作吗?如果没有,请尝试首先在单独的终端上启动metro捆绑程序(npm启动您的项目)。这听起来像是我得到的。如果您尝试在不首先运行metro bundler的情况下执行npm启动ios,那么工作目录将设置在node_模块中,这就是它找不到任何文件的原因