an object is a standalone entity, with properties and type. Compare it with a cup, for example. A cup is an object, with properties. A cup has a color, a design, weight, a material it is made of, etc. The same way, JavaScript objects can have properties, which define their characteristics.
you can access the proparties or method using dot notation .you can also access the properties with square brackets .
When a web page is loaded, the browser creates a Document Object Model of the page.The HTML DOM model is constructed as a tree of Objects:
- document nodes .
- element nodes .
- attribute nodes, and text nodes.
- locate the node that represent the element you want to work with .
- use it is text contant ,child element and attributes
method that find the element in DOM tree are called DOM queries.when you want to use the element more than once ,you should store the result of query in a variable .
methods that select indivedual elements: git element id and query selector can both search an entire document and return indvidual element . both use similar syntax .
there are two ways to select an element from node list : the item() method and array syntax .both requier the index of the element that you want .
repeating actions for an entire nodelist : when you have a node list , you can loop through each node in the collection and apply the same statments to each.
once you have an element node , you can use other proparties and method on that element node to access and change it's attributes
- select the element node and follow it with period symbol .
- use one of the methods or proparties to work with that element attributes.

