javascript-and-json Flashcards

1
Q

What is JSON?

A

JSON is an open standard file format and data interchange format that uses human-readable text to store and transmit data objects consisting of attribute–value pairs and arrays. It is a common data format with diverse uses in electronic data interchange, including that of web applications with servers.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What are serialization and deserialization?

A

Serialization means to convert an object into that string, and deserialization is its inverse operation (convert string -> object).

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Why are serialization and deserialization useful?

A

You can stream data quickly, “a whole lotta lil chunks”.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

How do you serialize a data structure into a JSON string using JavaScript?

A

stringify method

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

How do you deserialize a JSON string into a data structure using JavaScript?

A

parse method

How well did you know this?
1
Not at all
2
3
4
5
Perfectly