Chapter 8
Objects
Key Skills & Concepts
• Defining Objects
• Creating Objects
• Using Prototypes
• Object Statements
• Understanding Predefined JavaScript Objects
Objects provide you with even more flexibility in your scripts. They can be used as another way to store data, or can be used to create reusable structures. In this chapter, you will learn what JavaScript objects are, how to create objects, and how to make use of some of the predefined objects.
Defining Objects
Since JavaScript is a prototype-based language, objects work differently than they do in class-based languages.
JavaScript objects are basically a collection of ...