let obj = { name: "zhangsan" } console.log(obj) //{name: "zhangsan"} let copyObj = JSON.parse(JSON.stringify(obj)) copyObj.name = "lisi" console.log(obj) //{name: "zhangsan"} console.log(copyObj) //{name: "lisi"}