Entering and Exiting Fullscreen
The Fullscreen API gives you a simple way to make any element on your page fill the entire screen. This is especially useful for images, videos, games, or any content you want users to focus on without distractions. The API works by calling methods directly on DOM elements or the document object.
You use the requestFullscreen method to make an element enter fullscreen mode. This method is available on most HTML elements. When you no longer want fullscreen mode, you call exitFullscreen on the document object to return to normal view. Browsers also provide events to let you know when fullscreen mode changes, which is helpful for updating your UI or handling user actions.
index.html
style.css
script.js
Danke für Ihr Feedback!
Fragen Sie AI
Fragen Sie AI
Fragen Sie alles oder probieren Sie eine der vorgeschlagenen Fragen, um unser Gespräch zu beginnen
Can you show me an example of how to use the Fullscreen API in JavaScript?
What are some common use cases for the Fullscreen API?
Are there any browser compatibility issues I should be aware of with the Fullscreen API?
Großartig!
Completion Rate verbessert auf 7.14
Entering and Exiting Fullscreen
Swipe um das Menü anzuzeigen
The Fullscreen API gives you a simple way to make any element on your page fill the entire screen. This is especially useful for images, videos, games, or any content you want users to focus on without distractions. The API works by calling methods directly on DOM elements or the document object.
You use the requestFullscreen method to make an element enter fullscreen mode. This method is available on most HTML elements. When you no longer want fullscreen mode, you call exitFullscreen on the document object to return to normal view. Browsers also provide events to let you know when fullscreen mode changes, which is helpful for updating your UI or handling user actions.
index.html
style.css
script.js
Danke für Ihr Feedback!