source: trip-planner-front/node_modules/webpack-merge/dist/merge-with.js@ 76712b2

Last change on this file since 76712b2 was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago

initial commit

  • Property mode set to 100644
File size: 1.1 KB
RevLine 
[6a3a178]1"use strict";
2var __read = (this && this.__read) || function (o, n) {
3 var m = typeof Symbol === "function" && o[Symbol.iterator];
4 if (!m) return o;
5 var i = m.call(o), r, ar = [], e;
6 try {
7 while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
8 }
9 catch (error) { e = { error: error }; }
10 finally {
11 try {
12 if (r && !r.done && (m = i["return"])) m.call(i);
13 }
14 finally { if (e) throw e.error; }
15 }
16 return ar;
17};
18exports.__esModule = true;
19function mergeWith(objects, customizer) {
20 var _a = __read(objects), first = _a[0], rest = _a.slice(1);
21 var ret = first;
22 rest.forEach(function (a) {
23 ret = mergeTo(ret, a, customizer);
24 });
25 return ret;
26}
27function mergeTo(a, b, customizer) {
28 var ret = {};
29 Object.keys(a)
30 .concat(Object.keys(b))
31 .forEach(function (k) {
32 var v = customizer(a[k], b[k], k);
33 ret[k] = typeof v === "undefined" ? a[k] : v;
34 });
35 return ret;
36}
37exports["default"] = mergeWith;
38//# sourceMappingURL=merge-with.js.map
Note: See TracBrowser for help on using the repository browser.