JavaScript- Browser Object Model

The BOM is the Browser Object Model, which deals with browser components aside from the document, like historylocationnavigator and screen (as well as some others that vary by browser) .
The BOM (Browser Object Model) consists of the objects like navigatorhistoryscreenlocation and document which are children of window. In the document node is the DOM (Document Object Model), the document object model, which represents the contents of the page. You can manipulate it using javascript.

So we can say that The Browser Object Model (BOM) is used to interact with the browser.
The default object of browser is window means you can call all the functions of window by specifying window or directly.

Example -1:

<!DOCTYPE html>
<html>
<body>

<p id="output"></p>

<script>
var w = window.innerWidth
|| document.documentElement.clientWidth
|| document.body.clientWidth;

var h = window.innerHeight
|| document.documentElement.clientHeight
|| document.body.clientHeight;

var outputParagraph = document.getElementById("output");
outputParagraph.innerHTML = "right Now the inner window width: " + w + ", height: " + h + ".";
</script>

</body>
</html>
output will be -