RCTView 为 validAttributes 生成的视图配置与本机不匹配

Mar*_*ang 5 mobile android react-native

React Native 应用程序加载后崩溃,即使它一周前还在工作。

生成的错误是:

RCTView generated view config for validAttributes does not match native, missing: onPointerOut onTouchCancel onStartShouldSetResponder onTouchStart gap onStartShouldSetResponderCapture onMoveShouldSetResponderCapture columnGap onPointerLeaveCapture onTouchEnd accessibilityCollection onResponderTerminationRequest...

我试过了:

  • 卸载应用程序,
  • 删除android文件夹中的build文件夹,
  • 重新安装节点包,
  • 重置 npm 缓存

应用程序通常会立即启动,不会出现任何错误。

小智 0

就我而言,问题是由于 expo、react、react-native 中的版本不匹配,我已删除所有节点模块并安装了适当的版本, 在此处输入图像描述