navigator.getAutoplayPolicy does not work in Google Chrome

218 Views Asked by At

I test an app on Google Chrome Version 120.0.6099.71 (Official Build) (64-bit). I am trying to write a function to check if autoplay is allowed or not. I tried:

navigator.getAutoplayPolicy("mediaelement");

It works fine with FireFox 120.0.1 (64-bit). but in Chrome it returns error:

Uncaught TypeError: navigator.getAutoplayPolicy is not a function

I could not able to find any work around for Google Chrome. Is there such work around?

1

There are 1 best solutions below

0
Aracturat On

getAutoplayPolicy is not supported by Chrome 120 yet.

To check autoplay is disabled look at another question