react-native-fast-image icon indicating copy to clipboard operation
react-native-fast-image copied to clipboard

react-native 0.73 [FFFastImageView setOnClick:]: unrecognized selector sent to instance

Open cbjs opened this issue 1 year ago • 7 comments

Exception thrown while executing UI block: -[FFFastImageView setOnClick:]: unrecognized selector sent to instance 0x1355be2c0

__44-[RCTUIManager flushUIBlocksWithCompletion:]_block_invoke RCTUIManager.m:1205 __44-[RCTUIManager flushUIBlocksWithCompletion:]_block_invoke.207 __RCTExecuteOnMainQueue_block_invoke _dispatch_call_block_and_release _dispatch_client_callout _dispatch_main_queue_drain _dispatch_main_queue_callback_4CF CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE __CFRunLoopRun CFRunLoopRunSpecific GSEventRunModal -[UIApplication _run] UIApplicationMain main start_sim 0x0 0x0

cbjs avatar Dec 07 '23 06:12 cbjs

@cbjs This issue is only reproducible in iOS. Here is a workaround to it:

Just wrap your FastImage component inside any View.

ShivamKJJW avatar Dec 08 '23 07:12 ShivamKJJW

@cbjs This issue is only reproducible in iOS. Here is a workaround to it:

Just wrap your FastImage component inside any View.

Not working for me

ubaid-wp avatar Dec 29 '23 11:12 ubaid-wp

For me, this issue happened when I used a FastImage component as the direct child of the TouchableWithoutFeedback component. It can be fixed by either:

  • Wrapping the FastImage component in a View (as suggested by @ShivamKJJW)
  • Instead of TouchableWithoutFeedback, using TouchableOpacity with the activeOpacity being 1.0.

tranhoangduong1994 avatar Jan 02 '24 10:01 tranhoangduong1994

Any solution? I have the same probelm with all TouchableOpacity components

NiccoloCase avatar Jul 16 '24 16:07 NiccoloCase

the solution is this:

https://github.com/TheWidlarzGroup/react-native-video/pull/3688/files

you need the following to FFFastImageView.m using patch-package:

- (void)setOnClick:(id)sender {
    // Implementation can be left empty as in the Swift version
}

chr4ss12 avatar Jul 22 '24 06:07 chr4ss12

the solution is this:

https://github.com/TheWidlarzGroup/react-native-video/pull/3688/files

you need the following to FFFastImageView.m using patch-package:

- (void)setOnClick:(id)sender {
    // Implementation can be left empty as in the Swift version
}

Worked for me 🙌🏻

naheed-shamim avatar Aug 21 '24 14:08 naheed-shamim