React Native 这些文件都不存在- Expo

b0zn9rqh  于 2023-10-22  发布在  React
关注(0)|答案(1)|浏览(184)

我在expo中有一个react-native项目,当我启动该项目时出现以下错误:

None of these files exist:
  * node_modules\react-native\Libraries\Components\DatePicker\DatePickerIOS(.native|.native.js|.js|.native.jsx|.jsx|.native.json|.json|.native.ts|.ts|.native.tsx|.tsx|.native.svg|.svg)
  * node_modules\react-native\Libraries\Components\DatePicker\DatePickerIOS\index(.native|.native.js|.js|.native.jsx|.jsx|.native.json|.json|.native.ts|.ts|.native.tsx|.tsx|.native.svg|.svg)
  15 | import typeof ActivityIndicator from './Libraries/Components/ActivityIndicator/ActivityIndicator';    
  16 | import typeof Button from './Libraries/Components/Button';
> 17 | import typeof DatePickerIOS from './Libraries/Components/DatePicker/DatePickerIOS';
     |                                   ^
  18 | import typeof DrawerLayoutAndroid from './Libraries/Components/DrawerAndroid/DrawerLayoutAndroid';    
  19 | import typeof FlatList from './Libraries/Lists/FlatList';
  20 | import typeof Image from './Libraries/Image/Image';

我在任何地方都不使用这个DatePickerIOS
我尝试重置该高速缓存,删除node_modules,删除node_modules内的“DatePickerIOS”,但错误到处出现,我不认为这只是

uelo1irk

uelo1irk1#

我已经通过升级到react-native 0.72.0解决了这个问题。

相关问题