Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Impara Entering and Exiting Fullscreen | Clipboard and Fullscreen Features
JavaScript Web APIs Essentials

bookEntering 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

index.html

style.css

style.css

script.js

script.js

copy
question mark

Which method is used to make an element enter fullscreen mode using the Fullscreen API?

Select the correct answer

Tutto è chiaro?

Come possiamo migliorarlo?

Grazie per i tuoi commenti!

Sezione 2. Capitolo 3

Chieda ad AI

expand

Chieda ad AI

ChatGPT

Chieda pure quello che desidera o provi una delle domande suggerite per iniziare la nostra conversazione

bookEntering and Exiting Fullscreen

Scorri per mostrare il menu

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

index.html

style.css

style.css

script.js

script.js

copy
question mark

Which method is used to make an element enter fullscreen mode using the Fullscreen API?

Select the correct answer

Tutto è chiaro?

Come possiamo migliorarlo?

Grazie per i tuoi commenti!

Sezione 2. Capitolo 3
some-alt