"The Document Object Model (DOM) is a programming interface for HTML and XML documents. It provides a structured representation of the document and it defines a way that the structure can be accessed from programs so that they can change the document structure, style and content." - Mozilla web docs
Familiarize yourself with all of the following reference material:
"When an HTML document is loaded into a web browser, it becomes a document object." - w3schools
window.document
document
document.URL
document.cookie
The document object provides properties and methods to access all node objects, from within JavaScript." - w3schools
document.childNodes
document.children
document.children[0].children
Reference: https://www.w3schools.com/js/js_htmldom_elements.asp.
// document.getElementById()
// document.getElementsByTagName()
// document.getElementsByClassName()
// document.querySelectorAll()
Reference: https://www.w3schools.com/js/js_htmldom_events.asp.
Reference: https://www.w3schools.com/jsref/met_document_addeventlistener.asp.
// document.addEventListener()
Again, reference: https://www.w3schools.com/js/js_htmldom_document.asp.