Table of Content
What is JSON?
A few notes on JSON:
- It is a lightweight format for storing and transporting data
- The syntax is self-describing, making it easy for humans to read and understand
- Typically, JSON is used when data is sent from a server to a web page
JSON data is structured in two basic ways: a key/value pair or a collection of such pairs, or an ordered list. JSON allows six different types of data to be stored or transported, including:
- Language dependency
- Text only
- String vs. object
On the other hand, JSON is supported by more than 50 different programming languages, including popular languages such as:
This wide array of support makes JSON a flexible choice for data storage and transfer.
JSON data can only be presented in text. You cannot add comments or other lines of code to JSON. This rigidity is the reason why so many other programming languages can generate and parse JSON.
String Vs. Object