How to run function before fullscreenchange in Javascript

101 Views Asked by At

I have a function in Javascript that need to be called BEFORE event fullscreenchange occurs.

As stated on MDN, The fullscreenchange event is fired immediately AFTER the browser switches into or out of fullscreen mode.

Is there's any thing like this:

document.addEventListener('beforefullscreenchange', handlerFunction);

Thank you

0

There are 0 best solutions below