You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

13 lines
213 B

= Json 处理
[source,javaScript]
----
//字符串解析成对象
let json ='{"name":"中国"}'
let obj =JSON.parse(json)
console.log(obj)
//对象转成 json 串
json =JSON.stringify(obj)
console.log(json)
----