|
Last change
on this file was a762898, checked in by istevanoska <ilinastevanoska@…>, 5 months ago |
|
Added visualizations
|
-
Property mode
set to
100644
|
|
File size:
285 bytes
|
| Line | |
|---|
| 1 | import { clone } from './clone.mjs';
|
|---|
| 2 |
|
|---|
| 3 | function cloneWith(value, customizer) {
|
|---|
| 4 | if (!customizer) {
|
|---|
| 5 | return clone(value);
|
|---|
| 6 | }
|
|---|
| 7 | const result = customizer(value);
|
|---|
| 8 | if (result !== undefined) {
|
|---|
| 9 | return result;
|
|---|
| 10 | }
|
|---|
| 11 | return clone(value);
|
|---|
| 12 | }
|
|---|
| 13 |
|
|---|
| 14 | export { cloneWith };
|
|---|
Note:
See
TracBrowser
for help on using the repository browser.