You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've been dealing with this problem for a very long time.
The issue is the video stream does not start automatically when being implemented in a Cordova Android app. Eventually I've ran out of solutions and just resorted to simulating a screen tap which indeed helped.
But today I've found the true reason of this behavior.
Setting muted property of an HTMLVideoElement will not count as muted video for an Android WebView.
This does not work:
videoElement.muted = true;
You have to add the muted=true attribute.
This is the proper way:
videoElement.setAttribute('muted', true);
Basically as I understand, the Android WebView will ignore autoplay attribute if it doesn't detect a muted attribute.
Please implement this fix. There is a lot of frustrated people out there who were not able to solve this for years. This issue seems to be unique for Android WebView.
The text was updated successfully, but these errors were encountered:
I've been dealing with this problem for a very long time.
The issue is the video stream does not start automatically when being implemented in a Cordova Android app. Eventually I've ran out of solutions and just resorted to simulating a screen tap which indeed helped.
But today I've found the true reason of this behavior.
Setting
muted
property of an HTMLVideoElement will not count as muted video for an Android WebView.This does not work:
videoElement.muted = true;
You have to add the
muted=true
attribute.This is the proper way:
videoElement.setAttribute('muted', true);
Basically as I understand, the Android WebView will ignore
autoplay
attribute if it doesn't detect amuted
attribute.Please implement this fix. There is a lot of frustrated people out there who were not able to solve this for years. This issue seems to be unique for Android WebView.
The text was updated successfully, but these errors were encountered: