DEV Community

Tanwi Kumari
Tanwi Kumari

Posted on

JSON(JAVASCRIPT OBJECT NOTATION)

JSON (Javascript Object Notation)

πŸ“ŒA common use of JSON is to exchange data to/from a server.

πŸ“Œ When receiving data from web server and sending data to a web
server the data has to be string.

πŸ“Œ Javascript has built in function for converting JSON string
into javascript object "JSON.parse()"and Javascript Object into
JSON string "JSON.stringify()"

πŸ“Œ JSON.parse() - To received data in pure text format(string)
from server and use it as javascript object use JSON.parse()

πŸ“ŒJSON.stringify() - To send a JavaScript object to a server in
pure text format(string)use JSON.stringify().

Thank you for reading. Sharing my daily learnings with all. Follow me to get more such content.

Top comments (0)