Webview freezes and goes blank
Bug description:
Some websites freeze and then go blank after navigating to another page on the site. It seems like some webpages are crashing the webview renderer on Android.
Happens only inside the webview, the website works correctly on chrome on the same device.
I have only noticed it happening with the website https://consolatio.com.br (see reproduction steps below).
It seems to be related to the CSS View Transitions API. After navigating to a new page, the console shows the following error.
Uncaught (in promise) AbortError: Transition was skippedI inspected some of the page's code, it makes use of the CSS View Transitions API.
I also see the following error on logcat at the exact moment the page goes blank:
026-07-24 16:42:46.224 12312-12761 chromium com.consolatio.debug E [ERROR:components/viz/service/transitions/surface_animation_manager.cc:274] No SurfaceAnimationManager for token : 0155BF51FF894A14E95984140762614FThis error is logged hundreds of times while I move around my finger on the screen when it is blank.
Seems to be an issue with webview, since it only happens inside the webview. Any pointers as to what the cause might be or possible workarounds are much appreciated.
Thanks in advance for your help!
To Reproduce:
- Clone the repo
yarn expo prebuild --platform androidyarn expo run:android- Once the home page loads, press on the banner (or any other link)
- Next page will start loading
Uncaught (in promise) AbortError: Transition was skippedlogged on webview console (inspected using chrome devtools)- Page freezes
- Press on the screen (or wait a bit and press again)
- Screen goes blank
- And the following error appears on logcat
026-07-24 16:42:46.224 12312-12761 chromium com.consolatio.debug E [ERROR:components/viz/service/transitions/surface_animation_manager.cc:274] No SurfaceAnimationManager for token : 0155BF51FF894A14E95984140762614F- Put app in background (go to Android home screen)
- Open app again
- Page renders normally
Expected behavior:
After opening a link, the page should not freeze and should not go blank on touch.
Screenshots/Videos:
https://github.com/user-attachments/assets/ea58d197-d171-40a8-a669-aebba57df491
Environment:
- OS: Android
- OS version: 15
- react-native version: 0.86.0
- react-native-webview version: 13.16.1
Source: react-native-webview/react-native-webview