diff --git a/components/WalletsCarousel.js b/components/WalletsCarousel.js index 8bf1f9159..4c7c716cd 100644 --- a/components/WalletsCarousel.js +++ b/components/WalletsCarousel.js @@ -154,7 +154,7 @@ const iStyles = StyleSheet.create({ }, }); -export const WalletCarouselItem = ({ item, _, onPress, handleLongPress, isSelectedWallet, customStyle }) => { +export const WalletCarouselItem = React.memo(({ item, _, onPress, handleLongPress, isSelectedWallet, customStyle }) => { const scaleValue = new Animated.Value(1.0); const { colors } = useTheme(); const { walletTransactionUpdateStatus } = useContext(BlueStorageContext); @@ -251,7 +251,7 @@ export const WalletCarouselItem = ({ item, _, onPress, handleLongPress, isSelect ); -}; +}); WalletCarouselItem.propTypes = { item: PropTypes.any, @@ -292,7 +292,7 @@ const WalletsCarousel = forwardRef((props, ref) => { ), // eslint-disable-next-line react-hooks/exhaustive-deps - [horizontal, selectedWallet, handleLongPress, onPress, preferredFiatCurrency, language], + [horizontal, selectedWallet, preferredFiatCurrency, language], ); const flatListRef = useRef();