Product → Web Applications
DOM
A tree representation of a web document that browsers expose to scripts for reading and modifying pages.
Motivation
The DOM is the browser’s object model for a document. It solves the problem of letting programs inspect and change page structure.
Mental model
JavaScript does not edit HTML text directly; it interacts with a live tree of nodes.
Where it fits
DOM belongs to the Product track, inside Web Applications. It connects to nearby concepts through the graph relationships on this page and in the graph explorer.
Common mistakes
- Updating too much DOM too often.
- Confusing the DOM with HTML source.
- Ignoring layout and rendering costs.
Related concepts
Use the metadata panel or return to the graph to explore concepts that this one requires or relates to.