@razorpay/blade
Version:
The Design System that powers Razorpay
28 lines (21 loc) • 741 B
JavaScript
import { getDefaultExportFromCjs } from '../../../../_virtual/_commonjsHelpers.js';
import { __exports as uniqBy$1 } from '../../../../_virtual/uniqBy4.js';
(function (exports) {
'use strict';
Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
function uniqBy(arr, mapper) {
const map = new Map();
for (let i = 0; i < arr.length; i++) {
const item = arr[i];
const key = mapper(item, i, arr);
if (!map.has(key)) {
map.set(key, item);
}
}
return Array.from(map.values());
}
exports.uniqBy = uniqBy;
} (uniqBy$1));
var uniqBy = /*@__PURE__*/getDefaultExportFromCjs(uniqBy$1);
export { uniqBy as default };
//# sourceMappingURL=uniqBy.js.map