Interview Question

What is BOM?

The BOM gives JavaScript information and controls for the browser window.

💡 Concept ✅ Quick Revision 🌐 HTML

Answer

The BOM is a group of browser objects outside the web page document. • It includes objects such as `window`, `location`, and `history`. • It lets JavaScript work with the browser window and URL. • The DOM handles the page; the BOM handles the browser around it.

💡 Simple Example

<p>console.log(window.location.href);</p>

⚡ Quick Revision

The BOM gives JavaScript information and controls for the browser window.