Entering fullscreen on play ? #1137
Answered
by
luwes
sebastiandammark
asked this question in
Q&A
|
Is it possible to enter fullscreen as soon as the video starts playing ? |
Answered by
luwes
May 14, 2025
Replies: 1 comment
|
yes, I think a good way is to listen to the See an example here https://xzn7qy.csb.app/ |
0 replies
Answer selected by
luwes
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
yes, I think a good way is to listen to the
mediaplayrequestevent on the media-controller and then just simulate a click action on the fullscreen button. Or if you don't have the fullscreen button in the UI, dispatch an event namedmediaenterfullscreenrequeston the media-controller.See an example here https://xzn7qy.csb.app/
https://codesandbox.io/p/devbox/media-chrome-w-video-forked-xzn7qy?file=%2Findex.html