es-toolkit 1.13.1-dev.307 → 1.13.1-dev.308
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 +14 -1
- package/dist/browser.js.map +1 -1
- package/dist/browser.mjs +1 -1
- package/dist/{chunk-3KV2FFWH.mjs → chunk-6XYJRXID.mjs} +16 -2
- package/dist/chunk-6XYJRXID.mjs.map +1 -0
- package/dist/compat/index.d.mts +32 -2
- package/dist/compat/index.d.ts +32 -2
- package/dist/compat/index.js +14 -1
- package/dist/compat/index.js.map +1 -1
- package/dist/compat/index.mjs +3 -4
- package/package.json +1 -1
- package/umd/browser.global.js +1 -1
- package/dist/chunk-3KV2FFWH.mjs.map +0 -1
package/dist/browser.js
CHANGED
|
@@ -63,7 +63,7 @@ __export(compat_exports, {
|
|
|
63
63
|
dropRightWhile: () => dropRightWhile,
|
|
64
64
|
dropWhile: () => dropWhile,
|
|
65
65
|
endsWith: () => endsWith,
|
|
66
|
-
fill: () =>
|
|
66
|
+
fill: () => fill2,
|
|
67
67
|
first: () => head,
|
|
68
68
|
flatMap: () => flatMap,
|
|
69
69
|
flatten: () => flatten,
|
|
@@ -1148,6 +1148,19 @@ function difference2(arr, ...values) {
|
|
|
1148
1148
|
return difference(arr1, arr2);
|
|
1149
1149
|
}
|
|
1150
1150
|
|
|
1151
|
+
// src/compat/array/fill.ts
|
|
1152
|
+
function fill2(array, value, start = 0, end = array.length) {
|
|
1153
|
+
start = Math.floor(start);
|
|
1154
|
+
end = Math.floor(end);
|
|
1155
|
+
if (!start) {
|
|
1156
|
+
start = 0;
|
|
1157
|
+
}
|
|
1158
|
+
if (!end) {
|
|
1159
|
+
end = 0;
|
|
1160
|
+
}
|
|
1161
|
+
return fill(array, value, start, end);
|
|
1162
|
+
}
|
|
1163
|
+
|
|
1151
1164
|
// src/compat/_internal/isIndex.ts
|
|
1152
1165
|
var IS_UNSIGNED_INTEGER = /^(?:0|[1-9]\d*)$/;
|
|
1153
1166
|
function isIndex(value) {
|