react-native-ios-context-menu icon indicating copy to clipboard operation
react-native-ios-context-menu copied to clipboard

Cannot use inside Animated.FlatList

Open morajabi opened this issue 2 years ago • 8 comments

It opens correctly but on close it crashes the app.

https://github.com/dominicstop/react-native-ios-context-menu/assets/12202757/73e821d5-682e-4ac6-bc55-2b1fc967e9d9

CleanShot 2023-11-04 at 13 18 31@2x

error

Error: domain: react-native-ios-utilities - code: nilReactBridge - description: Unable to get ref. to react bridge - fileName: /Users/mo/dev/noor/node_modules/react-native-ios-utilities/ios/Sources/Helpers/RNIModuleHelpers.swift - functionName: getReactBridge(withErrorType:) - lineNumber: 18 - columnNumber: 27

morajabi avatar Nov 04 '23 09:11 morajabi

Possible duplicate or #70

nandorojo avatar Nov 04 '23 12:11 nandorojo

Have you tried FlashList

nandorojo avatar Nov 04 '23 13:11 nandorojo

And are you on RN 0.72.5+

nandorojo avatar Nov 04 '23 13:11 nandorojo

Unfortunately FlashList falls short for inverted usecase, messages frequently overlap over each other and it doesn't support sticky items properly while inverted. We recently had to switch to FlatList. We use RN 0.72.6.

morajabi avatar Nov 04 '23 14:11 morajabi

And making FlashList not be animated fixes it?

nandorojo avatar Nov 04 '23 23:11 nandorojo

@nandorojo Yes. But also I noticed a new thing. Clicking one of our menu items caused the crash, but in production it was fine.

morajabi avatar Nov 05 '23 06:11 morajabi

In my case, quitting the dev app and restarting fixed this

nandorojo avatar Nov 05 '23 13:11 nandorojo

I'll try again with Animated FlatList with this suggestion

morajabi avatar Nov 05 '23 14:11 morajabi