securityos/node_modules/@monaco-editor/loader/lib/es/utils/deepMerge.js

15 lines
414 B
JavaScript
Raw Normal View History

2024-09-06 15:32:35 +00:00
import { objectSpread2 as _objectSpread2 } from '../_virtual/_rollupPluginBabelHelpers.js';
function merge(target, source) {
Object.keys(source).forEach(function (key) {
if (source[key] instanceof Object) {
if (target[key]) {
Object.assign(source[key], merge(target[key], source[key]));
}
}
});
return _objectSpread2(_objectSpread2({}, target), source);
}
export default merge;