1. object 转换为 string obj = { name: 'ws', age: 18, sex: '♂' } str = JSON.stringify(obj) // output: "{"name":"ws","age":18,"sex":"♂"}" 2. string转换为object str = '{"name":"ws","age":18,"sex":"♂"}' obj = JSON.parse(str) // output: {name: "ws", age: 18, sex: "♂"}