@opfr/utils-lang 0.14.0 → 0.15.0

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.
Files changed (48) hide show
  1. package/dist/array.d.ts +2 -3
  2. package/dist/common.d.ts +0 -1
  3. package/dist/date.d.ts +0 -1
  4. package/dist/duration.d.ts +0 -1
  5. package/dist/function.d.ts +0 -1
  6. package/dist/generics.d.ts +0 -1
  7. package/dist/index.d.ts +0 -1
  8. package/dist/index.es.js +159 -2734
  9. package/dist/index.umd.cjs +1 -0
  10. package/dist/locales/fr.d.ts +0 -1
  11. package/dist/number.d.ts +0 -1
  12. package/dist/object.d.ts +0 -1
  13. package/dist/string.d.ts +0 -1
  14. package/package.json +6 -5
  15. package/dist/array.d.ts.map +0 -1
  16. package/dist/array.js +0 -84
  17. package/dist/array.js.map +0 -1
  18. package/dist/common.d.ts.map +0 -1
  19. package/dist/common.js +0 -14
  20. package/dist/common.js.map +0 -1
  21. package/dist/date.d.ts.map +0 -1
  22. package/dist/date.js +0 -63
  23. package/dist/date.js.map +0 -1
  24. package/dist/duration.d.ts.map +0 -1
  25. package/dist/duration.js +0 -34
  26. package/dist/duration.js.map +0 -1
  27. package/dist/function.d.ts.map +0 -1
  28. package/dist/function.js +0 -4
  29. package/dist/function.js.map +0 -1
  30. package/dist/generics.d.ts.map +0 -1
  31. package/dist/generics.js +0 -2
  32. package/dist/generics.js.map +0 -1
  33. package/dist/index.d.ts.map +0 -1
  34. package/dist/index.js +0 -9
  35. package/dist/index.js.map +0 -1
  36. package/dist/index.umd.js +0 -10
  37. package/dist/locales/fr.d.ts.map +0 -1
  38. package/dist/locales/fr.js +0 -85
  39. package/dist/locales/fr.js.map +0 -1
  40. package/dist/number.d.ts.map +0 -1
  41. package/dist/number.js +0 -23
  42. package/dist/number.js.map +0 -1
  43. package/dist/object.d.ts.map +0 -1
  44. package/dist/object.js +0 -25
  45. package/dist/object.js.map +0 -1
  46. package/dist/string.d.ts.map +0 -1
  47. package/dist/string.js +0 -62
  48. package/dist/string.js.map +0 -1
package/dist/array.d.ts CHANGED
@@ -2,8 +2,8 @@ export declare const paginate: <T>(array: T[], pageSize: number) => T[][];
2
2
  export declare const groupBy: <T extends object, K extends string | number>(array: T[], key: (i: T) => K) => Record<K, T[]>;
3
3
  export declare const groupByOccurrence: <T extends string | number | object, K extends string | number>(array: T[], key: (i: T) => K) => [K, number][];
4
4
  export declare const sortBy: <T extends object, K extends string | number>(array: T[], key: (i: T) => K) => T[];
5
- export declare const mutuallyInclusive: <T>(array1: T[], array2: T[], key?: (i: T) => T | string | number) => T[];
6
- export declare const exclude: <T>(array: T[], exclude: T[], key?: (i: T) => T | string | number) => T[];
5
+ export declare const mutuallyInclusive: <T>(array1: T[], array2: T[], key?: (i: T) => string | number | T) => T[];
6
+ export declare const exclude: <T>(array: T[], exclude: T[], key?: (i: T) => string | number | T) => T[];
7
7
  export declare const unique: <T extends object, K extends string | number>(array: T[], key: (i: T) => K) => K[];
8
8
  export declare const uniquePreserve: <T extends object, K extends string | number>(array: T[], key: (i: T) => K) => T[];
9
9
  export declare const shuffle: <T>(array: T[]) => T[];
@@ -22,4 +22,3 @@ export type RangeParams = {
22
22
  };
23
23
  export declare const range: ({ start, stop, step }: RangeParams) => number[];
24
24
  export declare const arrayToRecord: <TKey extends string | number, TValue>(array: [TKey, TValue][]) => Record<TKey, TValue>;
25
- //# sourceMappingURL=array.d.ts.map
package/dist/common.d.ts CHANGED
@@ -1,3 +1,2 @@
1
1
  export declare const isDefined: <T>(value: T) => value is NonNullable<T>;
2
2
  export declare const isJSON: (json: unknown) => boolean;
3
- //# sourceMappingURL=common.d.ts.map
package/dist/date.d.ts CHANGED
@@ -7,4 +7,3 @@ export declare const yesterday: () => Date;
7
7
  export declare const hasExpire: (date: Date) => boolean;
8
8
  export declare const roundDate: (date?: Date, minutes?: number) => Date;
9
9
  export declare const precise: (timestamp: number) => string | undefined;
10
- //# sourceMappingURL=date.d.ts.map
@@ -1,4 +1,3 @@
1
1
  export declare const isDuration: (str: string | null) => boolean;
2
2
  export declare const durationToMs: (str: string) => number | null | undefined;
3
3
  export declare const formatDuration: (str: string) => string | null | undefined;
4
- //# sourceMappingURL=duration.d.ts.map
@@ -1,2 +1 @@
1
1
  export declare const isFunction: (fn: unknown) => fn is Function;
2
- //# sourceMappingURL=function.d.ts.map
@@ -1,4 +1,3 @@
1
1
  export type NonNullableProperty<T extends object, K extends keyof T> = Omit<T, K> & {
2
2
  [P in K]-?: NonNullable<T[P]>;
3
3
  };
4
- //# sourceMappingURL=generics.d.ts.map
package/dist/index.d.ts CHANGED
@@ -7,4 +7,3 @@ export * from './string';
7
7
  export * from './function';
8
8
  export * from './object';
9
9
  export type * from './generics';
10
- //# sourceMappingURL=index.d.ts.map