mixlea-utils-js 0.1.77 → 0.1.79
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/mixlea-utils-js.js +671 -649
- package/dist/mixlea-utils-js.umd.js +2 -2
- package/dist/types/index.d.ts +4 -0
- package/package.json +1 -1
package/dist/types/index.d.ts
CHANGED
|
@@ -121,6 +121,8 @@ export declare function arrayLastItem<T>(arr: T[]): T;
|
|
|
121
121
|
|
|
122
122
|
export declare function arrayLastPick<T = any>(arr: T[], num?: number): any[];
|
|
123
123
|
|
|
124
|
+
export declare function arrayLoopInsert<R extends Record<string, any>>(arr: R[], inserts: (prevRow: R | null, nextRow: R | null, arr: R[]) => R[] | null | undefined): R[];
|
|
125
|
+
|
|
124
126
|
export declare function arrayMap<T = any, R = any>(arr: T[], callback: (record: T, index: number, arr: T[]) => R): R[];
|
|
125
127
|
|
|
126
128
|
export declare function arrayMapToObject(arr: any[], fieldFn: (arrItem: any) => string, valueFn: (arrItem: any) => any, option?: {
|
|
@@ -1153,6 +1155,8 @@ export declare function percentFormatter<T = unknown>(value: T, options?: {
|
|
|
1153
1155
|
precisionPad?: boolean;
|
|
1154
1156
|
}): string;
|
|
1155
1157
|
|
|
1158
|
+
export declare function pickObjectArrayField<T extends Record<string, any>, K extends keyof T>(arr: T[], field: K, defaultValue?: T[K]): T[K][];
|
|
1159
|
+
|
|
1156
1160
|
export declare function pipe<A extends unknown[], B>(ab: (this: void, ...a: A) => B): (...args: A) => B;
|
|
1157
1161
|
|
|
1158
1162
|
export declare function pipe<A extends unknown[], B, C>(ab: (this: void, ...a: A) => B, bc: (this: void, b: B) => C): (...args: A) => C;
|