https://www.jianshu.com/p/d5f572dd3776
数组的扩展,两个数组的合并
const target = { a: 1 }; const source1 = { b: 2 }; const source2 = { c: 3 }; Object.assign(target, source1, source2); target // {a:1, b:2, c:3}
https://www.jianshu.com/p/d5f572dd3776
数组的扩展,两个数组的合并
const target = { a: 1 }; const source1 = { b: 2 }; const source2 = { c: 3 }; Object.assign(target, source1, source2); target // {a:1, b:2, c:3}