react-native-hold-menu icon indicating copy to clipboard operation
react-native-hold-menu copied to clipboard

fix: fix for unreactive react keys

Open NoodleOfDeath opened this issue 2 years ago • 2 comments

Summary

This addresses

  • https://github.com/enesozturk/react-native-hold-menu/issues/86
  • https://github.com/enesozturk/react-native-hold-menu/issues/105
  • https://github.com/enesozturk/react-native-hold-menu/issues/106

MenuItems uses an numeric index for reactive keys, so react has no idea that the item needs to be recomputed when the arrow function differs between two items but all other properties are the same. This should be exposed to the developers and required to prevent the side effect of the first onPress arrow function persisting for all items that only differ by their onPress property.

NoodleOfDeath avatar Jul 04 '23 19:07 NoodleOfDeath

This should be merged ASAP. @enesozturk

ansh avatar Jul 06 '23 17:07 ansh

Need this also 🙏🙏🙏 @enesozturk

kesha-antonov avatar Nov 24 '23 10:11 kesha-antonov