Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix ReanimatedSwipeable reanimated warnings #3365

Merged

Conversation

juliendevleeschauwer
Copy link
Contributor

Description

Fix - WARN [Reanimated] Reading from value during component render. in react-native-gesture-handler version 2.22.1

This warning appear when you use Swipeable component.

Change :
in src/components/ReanimatedSwipeable.tsx
replace rowWidth.value to rowWidth in the dependency array of updateElementWidths callback.

#3170 #3320

Test plan

Tested on Samsung Galaxy A52, android emulator and Iphone 13

Change rowWidth.value to rowWidth in the dependency array of updateElementWidths callback. To resolve warning : WARN  [Reanimated] Reading from `value` during component render. Please ensure that you do not access the `value` property or use `get` method of a shared value while React is rendering a component.
@latekvo
Copy link
Contributor

latekvo commented Jan 29, 2025

Thanks for the fix!

@latekvo latekvo changed the title Update ReanimatedSwipeable.tsx Fix ReanimatedSwipeable reanimated warnings Jan 29, 2025
@latekvo latekvo merged commit b3d8fd9 into software-mansion:main Jan 29, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants