merge-anything 5.1.2 → 5.1.3

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/index.cjs CHANGED
@@ -109,7 +109,12 @@ function mergeAndConcat(object, ...otherObjects) {
109
109
  // }
110
110
  // const ba1: Barguments = { key: 'value1' }
111
111
  // const ba2: Barguments = { key: 'value2' }
112
- // const ba = merge(ba1, ba2)
112
+ // const ba = merge(ba1, ba2)
113
+ // interface Carguments {
114
+ // key: string
115
+ // }
116
+ // const ca = merge<Carguments, Carguments[]>({ key: 'value1' }, { key: 'value2' })
117
+ // type P = Pop<Carguments[]>
113
118
 
114
119
  exports.concatArrays = concatArrays;
115
120
  exports.merge = merge;
package/dist/index.es.js CHANGED
@@ -107,6 +107,11 @@ function mergeAndConcat(object, ...otherObjects) {
107
107
  // }
108
108
  // const ba1: Barguments = { key: 'value1' }
109
109
  // const ba2: Barguments = { key: 'value2' }
110
- // const ba = merge(ba1, ba2)
110
+ // const ba = merge(ba1, ba2)
111
+ // interface Carguments {
112
+ // key: string
113
+ // }
114
+ // const ca = merge<Carguments, Carguments[]>({ key: 'value1' }, { key: 'value2' })
115
+ // type P = Pop<Carguments[]>
111
116
 
112
117
  export { concatArrays, merge, mergeAndCompare, mergeAndConcat };
@@ -26,4 +26,4 @@ export declare type Length<L extends List> = L['length'];
26
26
  * ```ts
27
27
  * ```
28
28
  */
29
- export declare type Pop<L extends List> = L extends readonly [] ? L : L extends readonly [...any, infer Last] ? Last : L;
29
+ export declare type Pop<L extends List> = L extends readonly [] ? never : L extends [...unknown[], infer Last] ? Last : L extends (infer T)[] ? T : never;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "merge-anything",
3
- "version": "5.1.2",
3
+ "version": "5.1.3",
4
4
  "sideEffects": false,
5
5
  "type": "module",
6
6
  "description": "Merge objects & other types recursively. A simple & small integration.",