Hour 8. Meet JSON

What You’ll Learn in This Hour

• What JSON is

• How to simulate associative arrays

• About JSON and objects

• Accessing JSON data

• Data serialization with JSON

• How to keep JSON secure

In the previous hour, you saw how to directly instantiate an object using the new Object() syntax. In this hour you learn about JavaScript Object Notation (JSON) which, as its name implies, offers another way to create object instances, and which can also act as a general-purpose data exchange syntax.

What Is JSON?

JSON (pronounced “Jason”) is a simple and compact notation for JavaScript objects. Once expressed in JSON, objects can easily be converted to strings to be stored and transmitted (across networks or between applications, for instance). ...

Get Sams Teach Yourself JavaScript™ in 24 Hours, Fifth Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.