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

Import from react-native-reanimated causes webview full reload on its style change #6805

Open
zarv1k opened this issue Dec 10, 2024 · 1 comment
Labels
Platform: Android This issue is specific to Android Repro provided A reproduction with a snippet of code, snack or repo is provided

Comments

@zarv1k
Copy link

zarv1k commented Dec 10, 2024

Description

In project that uses react-native-webview and react-native-reanimated there are some anomalies while using this libraries together on Android. If you just import an use (even just console) something from react-native-reanimated the Webview on its props change goes to full component reload.

There is no such issue on iOS and I was able to reproduce it on Android only.

Screen.Recording.2024-12-10.at.17.17.17.mov

Steps to reproduce

  1. Open provided example repository and run the provided example on Android to reproduce the issue:
  2. Press "Get started" on webpage
  3. Press "change webview style" and you can see unexpected the webivew full reload on Android. That's the issue.
  4. Comment out the line console.log(useAnimatedStyle); in TestComponent, so that there is no more any usage from react-native-reanimated
  5. Open dev menu and press reload
  6. Repeat steps 1-2 from this list to ensure that there is NO more issue with webview full reload on Android.

Snack or a link to a repository

https://github.com/zarv1k/WebviewPropsChangeReloadIssue

Reanimated version

3.16.3

React Native version

0.76.3

Platforms

Android

JavaScript runtime

Hermes

Workflow

React Native

Architecture

Fabric (New Architecture)

Build type

Debug app & dev bundle

Device

Android emulator

Device model

No response

Acknowledgements

Yes

@zarv1k
Copy link
Author

zarv1k commented Dec 10, 2024

Actually I'm not sure whether it's the issue in react-native-reanimated or in react-native-webview. I'm going to open the similar issue in react-native-webview repository.

@github-actions github-actions bot added Platform: Android This issue is specific to Android Repro provided A reproduction with a snippet of code, snack or repo is provided labels Dec 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Platform: Android This issue is specific to Android Repro provided A reproduction with a snippet of code, snack or repo is provided
Projects
None yet
Development

No branches or pull requests

1 participant