January 2018
Intermediate to advanced
678 pages
20h 16m
English
You’ve been using objects for quite some time. The objects have come from the browser’s Document Object Model (DOM). The DOM models all of the parts of a web page document as nodes in a node tree. For example, the following code fragment shows how you can use the DOM’s document object and its getElementById method to retrieve the object associated with a web page element that has “street-address” for its id attribute:
streetAddress = document.getElementById("street-address");
In this chapter, you’ll still use prebuilt objects that come from the DOM, but you’ll also define structures for new types of objects and use those structures to create the objects. The structures you define and the objects you create will help you organize ...
Read now
Unlock full access