@webundsoehne/deep-merge
Advanced tools
Comparing version 2.1.1-beta.1 to 2.2.0-beta.1
@@ -7,3 +7,3 @@ var __create = Object.create; | ||
var __hasOwnProp = Object.prototype.hasOwnProperty; | ||
var __markAsModule = (target) => __defProp(target, "__esModule", { value: true }); | ||
var __name = (target, value) => __defProp(target, "name", { value, configurable: true }); | ||
var __export = (target, all) => { | ||
@@ -13,18 +13,12 @@ for (var name in all) | ||
}; | ||
var __reExport = (target, module2, copyDefault, desc) => { | ||
if (module2 && typeof module2 === "object" || typeof module2 === "function") { | ||
for (let key of __getOwnPropNames(module2)) | ||
if (!__hasOwnProp.call(target, key) && (copyDefault || key !== "default")) | ||
__defProp(target, key, { get: () => module2[key], enumerable: !(desc = __getOwnPropDesc(module2, key)) || desc.enumerable }); | ||
var __copyProps = (to, from, except, desc) => { | ||
if (from && typeof from === "object" || typeof from === "function") { | ||
for (let key of __getOwnPropNames(from)) | ||
if (!__hasOwnProp.call(to, key) && key !== except) | ||
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable }); | ||
} | ||
return target; | ||
return to; | ||
}; | ||
var __toESM = (module2, isNodeMode) => { | ||
return __reExport(__markAsModule(__defProp(module2 != null ? __create(__getProtoOf(module2)) : {}, "default", !isNodeMode && module2 && module2.__esModule ? { get: () => module2.default, enumerable: true } : { value: module2, enumerable: true })), module2); | ||
}; | ||
var __toCommonJS = /* @__PURE__ */ ((cache) => { | ||
return (module2, temp) => { | ||
return cache && cache.get(module2) || (temp = __reExport(__markAsModule({}), module2, 1), cache && cache.set(module2, temp), temp); | ||
}; | ||
})(typeof WeakMap !== "undefined" ? /* @__PURE__ */ new WeakMap() : 0); | ||
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target, mod)); | ||
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod); | ||
@@ -39,2 +33,3 @@ // src/index.ts | ||
}); | ||
module.exports = __toCommonJS(src_exports); | ||
@@ -48,9 +43,14 @@ // src/merge.ts | ||
} | ||
__name(deepMerge, "deepMerge"); | ||
function deepMergeWithUniqueMergeArray(t, ...s) { | ||
return s.reduce((o, val) => { | ||
return (0, import_deepmerge.default)(o, val ?? {}, { | ||
arrayMerge: (target, source) => [...target, ...source].filter(uniqueArrayFilter) | ||
arrayMerge: (target, source) => [ | ||
...target, | ||
...source | ||
].filter(uniqueArrayFilter) | ||
}); | ||
}, t); | ||
} | ||
__name(deepMergeWithUniqueMergeArray, "deepMergeWithUniqueMergeArray"); | ||
function deepMergeWithArrayOverwrite(t, ...s) { | ||
@@ -63,4 +63,4 @@ return s.reduce((o, val) => { | ||
} | ||
var uniqueArrayFilter = (item, index, array) => array.indexOf(item) === index; | ||
module.exports = __toCommonJS(src_exports); | ||
__name(deepMergeWithArrayOverwrite, "deepMergeWithArrayOverwrite"); | ||
var uniqueArrayFilter = /* @__PURE__ */ __name((item, index, array) => array.indexOf(item) === index, "uniqueArrayFilter"); | ||
// Annotate the CommonJS export names for ESM import in node: | ||
@@ -67,0 +67,0 @@ 0 && (module.exports = { |
@@ -7,3 +7,3 @@ var __create = Object.create; | ||
var __hasOwnProp = Object.prototype.hasOwnProperty; | ||
var __markAsModule = (target) => __defProp(target, "__esModule", { value: true }); | ||
var __name = (target, value) => __defProp(target, "name", { value, configurable: true }); | ||
var __export = (target, all) => { | ||
@@ -13,18 +13,12 @@ for (var name in all) | ||
}; | ||
var __reExport = (target, module2, copyDefault, desc) => { | ||
if (module2 && typeof module2 === "object" || typeof module2 === "function") { | ||
for (let key of __getOwnPropNames(module2)) | ||
if (!__hasOwnProp.call(target, key) && (copyDefault || key !== "default")) | ||
__defProp(target, key, { get: () => module2[key], enumerable: !(desc = __getOwnPropDesc(module2, key)) || desc.enumerable }); | ||
var __copyProps = (to, from, except, desc) => { | ||
if (from && typeof from === "object" || typeof from === "function") { | ||
for (let key of __getOwnPropNames(from)) | ||
if (!__hasOwnProp.call(to, key) && key !== except) | ||
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable }); | ||
} | ||
return target; | ||
return to; | ||
}; | ||
var __toESM = (module2, isNodeMode) => { | ||
return __reExport(__markAsModule(__defProp(module2 != null ? __create(__getProtoOf(module2)) : {}, "default", !isNodeMode && module2 && module2.__esModule ? { get: () => module2.default, enumerable: true } : { value: module2, enumerable: true })), module2); | ||
}; | ||
var __toCommonJS = /* @__PURE__ */ ((cache) => { | ||
return (module2, temp) => { | ||
return cache && cache.get(module2) || (temp = __reExport(__markAsModule({}), module2, 1), cache && cache.set(module2, temp), temp); | ||
}; | ||
})(typeof WeakMap !== "undefined" ? /* @__PURE__ */ new WeakMap() : 0); | ||
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target, mod)); | ||
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod); | ||
@@ -39,2 +33,3 @@ // src/merge.ts | ||
}); | ||
module.exports = __toCommonJS(merge_exports); | ||
var import_deepmerge = __toESM(require("deepmerge")); | ||
@@ -46,9 +41,14 @@ function deepMerge(t, ...s) { | ||
} | ||
__name(deepMerge, "deepMerge"); | ||
function deepMergeWithUniqueMergeArray(t, ...s) { | ||
return s.reduce((o, val) => { | ||
return (0, import_deepmerge.default)(o, val ?? {}, { | ||
arrayMerge: (target, source) => [...target, ...source].filter(uniqueArrayFilter) | ||
arrayMerge: (target, source) => [ | ||
...target, | ||
...source | ||
].filter(uniqueArrayFilter) | ||
}); | ||
}, t); | ||
} | ||
__name(deepMergeWithUniqueMergeArray, "deepMergeWithUniqueMergeArray"); | ||
function deepMergeWithArrayOverwrite(t, ...s) { | ||
@@ -61,4 +61,4 @@ return s.reduce((o, val) => { | ||
} | ||
var uniqueArrayFilter = (item, index, array) => array.indexOf(item) === index; | ||
module.exports = __toCommonJS(merge_exports); | ||
__name(deepMergeWithArrayOverwrite, "deepMergeWithArrayOverwrite"); | ||
var uniqueArrayFilter = /* @__PURE__ */ __name((item, index, array) => array.indexOf(item) === index, "uniqueArrayFilter"); | ||
// Annotate the CommonJS export names for ESM import in node: | ||
@@ -65,0 +65,0 @@ 0 && (module.exports = { |
{ | ||
"name": "@webundsoehne/deep-merge", | ||
"description": "Generic object deepmerge.", | ||
"version": "2.1.1-beta.1", | ||
"version": "2.2.0-beta.1", | ||
"author": "Backend <backend@webundsoehne.com>", | ||
"repository": "https://github.com/tailoredmedia/backend-nx-skeleton", | ||
"license": "ISC", | ||
"main": "./dist/index.js", | ||
"types": "./dist/index.d.ts", | ||
"repository": "https://github.com/tailoredmedia/backend-nx-skeleton", | ||
"publishConfig": { | ||
@@ -20,3 +20,3 @@ "access": "public" | ||
"build": "tsup-node", | ||
"dev:start": "tsup-node --watch", | ||
"dev:start": "tsup-node --silent --watch", | ||
"lint": "prettier --loglevel warn --write src/ && eslint --ext .ts,.js,.tsx,.jsx --fix src/", | ||
@@ -29,7 +29,7 @@ "lint:check": "eslint --ext .ts,.js,.tsx,.jsx src/", | ||
"lint-staged": { | ||
"./**/*.{ts,js,tsx,jsx}": [ | ||
"*.{ts,js,tsx,jsx}": [ | ||
"prettier --loglevel warn --write", | ||
"eslint --fix" | ||
], | ||
"./**/*.{json,md}": [ | ||
"*.{json,md}": [ | ||
"prettier --loglevel warn --write" | ||
@@ -36,0 +36,0 @@ ] |
@@ -1,5 +0,8 @@ | ||
[![Web&Söhne](https://webundsoehne.com/wp-content/uploads/2016/11/logo.png)](https://webundsoehne.com) | ||
<p align="center"> | ||
<a href="https://webundsoehne.com" target="blank"> | ||
<img src="https://webundsoehne.com/wp-content/uploads/webundsoehne-logo.png" width="320" alt="Web und Söhne - Logo" /> | ||
</a> | ||
</p> | ||
Web & Söhne is Austria's leading expert in programming and implementing complex and large web projects. | ||
Web & Söhne is Austrian's leading expert in programming and implementing complex and large web projects. | ||
--- | ||
@@ -6,0 +9,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
28
9317
7