es-toolkit 1.13.1-dev.297 → 1.13.1-dev.298
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/browser.js +3 -1
- package/dist/browser.js.map +1 -1
- package/dist/browser.mjs +2 -2
- package/dist/{chunk-BJWAMCFH.mjs → chunk-72G6BLM4.mjs} +2 -2
- package/dist/{chunk-U4JGKZ56.mjs → chunk-VRUTBJYS.mjs} +4 -2
- package/dist/{chunk-U4JGKZ56.mjs.map → chunk-VRUTBJYS.mjs.map} +1 -1
- package/dist/compat/index.js +3 -1
- package/dist/compat/index.js.map +1 -1
- package/dist/compat/index.mjs +2 -2
- package/dist/index.js +3 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1 -1
- package/dist/object/clone.js +3 -1
- package/dist/object/clone.js.map +1 -1
- package/dist/object/clone.mjs +1 -1
- package/dist/object/index.js +3 -1
- package/dist/object/index.js.map +1 -1
- package/dist/object/index.mjs +1 -1
- package/package.json +1 -1
- package/umd/browser.global.js +1 -1
- /package/dist/{chunk-BJWAMCFH.mjs.map → chunk-72G6BLM4.mjs.map} +0 -0
package/dist/compat/index.mjs
CHANGED
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
set,
|
|
11
11
|
startsWith,
|
|
12
12
|
zipObjectDeep
|
|
13
|
-
} from "../chunk-
|
|
13
|
+
} from "../chunk-72G6BLM4.mjs";
|
|
14
14
|
import "../chunk-NKLIE2OI.mjs";
|
|
15
15
|
import "../chunk-XT74R35S.mjs";
|
|
16
16
|
import {
|
|
@@ -71,7 +71,7 @@ import {
|
|
|
71
71
|
} from "../chunk-6CLH5YZ2.mjs";
|
|
72
72
|
import {
|
|
73
73
|
clone
|
|
74
|
-
} from "../chunk-
|
|
74
|
+
} from "../chunk-VRUTBJYS.mjs";
|
|
75
75
|
import {
|
|
76
76
|
flattenObject
|
|
77
77
|
} from "../chunk-XGQWTHW6.mjs";
|
package/dist/index.js
CHANGED
|
@@ -912,7 +912,9 @@ function clone(obj) {
|
|
|
912
912
|
return result;
|
|
913
913
|
}
|
|
914
914
|
if (typeof obj === "object") {
|
|
915
|
-
|
|
915
|
+
const prototype = Object.getPrototypeOf(obj);
|
|
916
|
+
const result = Object.create(prototype);
|
|
917
|
+
return Object.assign(result, obj);
|
|
916
918
|
}
|
|
917
919
|
return obj;
|
|
918
920
|
}
|