【文件属性】:
文件名称:deepmerge:一个用于深度(递归)合并Javascript对象的库
文件大小:22KB
文件格式:ZIP
更新时间:2021-05-07 21:03:12
JavaScript
深度合并
深度合并两个或更多对象的可枚举属性。
UMD捆绑包是723B缩小+压缩
入门
用法示例
const x = {
foo : { bar : 3 } ,
array : [ {
does : 'work' ,
too : [ 1 , 2 , 3 ]
} ]
}
const y = {
foo : { baz : 4 } ,
quux : 5 ,
array : [ {
does : 'work' ,
too : [ 4 , 5 , 6 ]
} , {
really : 'yes'
} ]
}
const output = {
foo : {
bar : 3 ,
baz : 4
} ,
array : [ {
does : 'work' ,
too : [ 1 , 2 , 3 ]
} , {
does : 'work'
【文件预览】:
deepmerge-master
----.travis.yml(53B)
----changelog.md(9KB)
----rollup.config.js(343B)
----index.js(3KB)
----license.txt(1KB)
----package.json(1KB)
----readme.md(6KB)
----test()
--------custom-is-mergeable-object.js(1KB)
--------prototype-poisoning.js(2KB)
--------merge.js(13KB)
--------typescript.ts(1014B)
--------merge-all.js(3KB)
--------custom-array-merge.js(2KB)
----package-lock.json(24KB)
----.npmignore(29B)
----index.d.ts(652B)
----.gitignore(20B)
----.editorconfig(113B)