I was facing this above error while using a react-native-video library (iOS Specific) react native version: 0.84.0 react-native-video version: 6.19.0

Saad Waheed Khan's user avatar

I solved the issue by following these steps:

navigate to: node_modules/react-native-video/ios/Video/RCTVideoManager.swift

Replace this portion of code:

override func view() -> UIView { return RCTVideo(eventDispatcher: (RCTBridge.current().eventDispatcher() as! RCTEventDispatcher)) }

with this:

override func view() -> UIView { return RCTVideo(eventDispatcher: nil) }

After replacing clear all issues and clean build folder in xcode (run the code again crash & error will disappear).

after running successfully hit this cmd (npx patch-package react-native-video) it will create the patch file and error will be removed forever

Saad Waheed Khan's user avatar

Sign up to request clarification or add additional context in comments.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.