UNPKG

es-toolkit

Version:

A state-of-the-art, high-performance JavaScript utility library with a small bundle size and strong type annotations.

19 lines (14 loc) 395 B
'use strict'; Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); const clone = require('./clone.js'); function cloneWith(value, customizer) { if (!customizer) { return clone.clone(value); } const result = customizer(value); if (result !== undefined) { return result; } return clone.clone(value); } exports.cloneWith = cloneWith;