The Document Object Model
In the JavaScript document object model (DOM), the primary document is an HTML page. As noted, the Window object, which includes frames, is at the top of the web browser hierarchy. However, the Document object contains the properties whose information is used by JavaScript. To strip away the mystery of what a DOM actually is, think of it as the Document object and all of its properties, including methods. Statements such as document.write() constitute the object (document) and a property/method (write()) that make up part of the model. To oversimplify a bit, you can say that the JavaScript DOM is the sum total of the Document object’s properties and methods, including the arrays automatically generated on an HTML page, ...
Get JavaScript Design now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.