JSON Flashcards
What is JSON?
JavaScript Object Notation; Commonly used for transmitting data in web applications.
What are serialization and deserialization?
Serialization is the process of turning an object in memory into a stream of bytes so you can do stuff like store it on disk or send it over the network.
Deserialization is the reverse process: turning a stream of bytes into an object in memory.
Why are serialization and deserialization useful?
So we can store data in main memory or send it over the network.
How do you serialize a data structure into a JSON string using JavaScript?
With the .stringify( ) method.
How do you deserialize a JSON string into a data structure using JavaScript?
With the .parse( ) method.