JSON
JSON parsing and stringification
JSON解析与字符串化
JSON is a simple object that serves as the namespace for the global ECMAScript 5 functions
JSON.parse() and JSON.stringify().JSON is not a constructor.
JSON是一个简单对象,用作全局函数JSON.parse() 和 JSON.stringify()的命名空间。JSON不是构造函数。
“JSON” stands for JavaScript Object Notation. JSON is a data serialization format based on
JavaScript literals, and can represent the null value, the boolean values true and false, floating-
point numbers (using JavaScript numeric literals), strings (using JavaScript string literals),
arrays of values (using JavaScript array literal syntax) and string to value mappings (using
JavaScript object literal syntax).
JSON表示javascript object notation. JSON是基于js直接量的数据序列化格式。可以表示null值,boolean值,浮点数值,字符串,值得数组,字符串到值得映射。
JSON.parse()
parse a JSON-formatted string
解析JSON格式的字符串
var data = JSON.parse(text);
JSON.stringify()
serialize an object, array or primitive value
序列化对象,数组,原始值