Node.js中合并两个复杂对象代码如下:
var obj1 = {
"name" : "myname",
"status" : 0,
"profile": { "sex":"m", "isactive" : true},
"strarr":["one", "three"],
"objarray": [
{
"id": 1,
"email": "
[email protected]",
"isactive":true
},
{
"id": 2,
"email": "
[email protected]",
"isactive":false
}
]
};本回答被提问者采纳