@joookiwi/type 1.1.0 → 1.2.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 (73) hide show
  1. package/dist/boolean (false).d.ts +0 -6
  2. package/dist/boolean (false).d.ts.map +1 -1
  3. package/dist/boolean (true).d.ts +0 -6
  4. package/dist/boolean (true).d.ts.map +1 -1
  5. package/dist/boolean.d.ts +0 -6
  6. package/dist/boolean.d.ts.map +1 -1
  7. package/dist/collection (array).d.ts +0 -6
  8. package/dist/collection (array).d.ts.map +1 -1
  9. package/dist/collection (map).d.ts +0 -6
  10. package/dist/collection (map).d.ts.map +1 -1
  11. package/dist/collection (mutable array).d.ts +0 -6
  12. package/dist/collection (mutable array).d.ts.map +1 -1
  13. package/dist/collection (mutable map).d.ts +0 -6
  14. package/dist/collection (mutable map).d.ts.map +1 -1
  15. package/dist/collection (mutable set).d.ts +0 -6
  16. package/dist/collection (mutable set).d.ts.map +1 -1
  17. package/dist/collection (set).d.ts +0 -6
  18. package/dist/collection (set).d.ts.map +1 -1
  19. package/dist/collection.d.ts +209 -6
  20. package/dist/collection.d.ts.map +1 -1
  21. package/dist/empty.d.ts +18 -24
  22. package/dist/empty.d.ts.map +1 -1
  23. package/dist/index.d.ts +0 -6
  24. package/dist/index.d.ts.map +1 -1
  25. package/dist/mixed.d.ts +0 -6
  26. package/dist/mixed.d.ts.map +1 -1
  27. package/dist/nullable.d.ts +0 -6
  28. package/dist/nullable.d.ts.map +1 -1
  29. package/dist/numeric (-1).d.ts +0 -6
  30. package/dist/numeric (-1).d.ts.map +1 -1
  31. package/dist/numeric (0).d.ts +0 -6
  32. package/dist/numeric (0).d.ts.map +1 -1
  33. package/dist/numeric (1).d.ts +0 -6
  34. package/dist/numeric (1).d.ts.map +1 -1
  35. package/dist/numeric (2).d.ts +0 -6
  36. package/dist/numeric (2).d.ts.map +1 -1
  37. package/dist/numeric (bigint).d.ts +0 -6
  38. package/dist/numeric (bigint).d.ts.map +1 -1
  39. package/dist/numeric (number).d.ts +0 -6
  40. package/dist/numeric (number).d.ts.map +1 -1
  41. package/dist/numeric.d.ts +0 -6
  42. package/dist/numeric.d.ts.map +1 -1
  43. package/dist/string (individual).d.ts +0 -6
  44. package/dist/string (individual).d.ts.map +1 -1
  45. package/dist/string.d.ts +0 -6
  46. package/dist/string.d.ts.map +1 -1
  47. package/dist/symbol.d.ts +0 -6
  48. package/dist/symbol.d.ts.map +1 -1
  49. package/package.json +3 -3
  50. package/src/boolean (false).ts +11 -6
  51. package/src/boolean (true).ts +11 -6
  52. package/src/boolean.ts +11 -6
  53. package/src/collection (array).ts +11 -6
  54. package/src/collection (map).ts +11 -6
  55. package/src/collection (mutable array).ts +11 -6
  56. package/src/collection (mutable map).ts +11 -6
  57. package/src/collection (mutable set).ts +11 -6
  58. package/src/collection (set).ts +11 -6
  59. package/src/collection.ts +242 -6
  60. package/src/empty.ts +29 -24
  61. package/src/index.ts +11 -6
  62. package/src/mixed.ts +11 -6
  63. package/src/nullable.ts +11 -6
  64. package/src/numeric (-1).ts +11 -6
  65. package/src/numeric (0).ts +11 -6
  66. package/src/numeric (1).ts +11 -6
  67. package/src/numeric (2).ts +11 -6
  68. package/src/numeric (bigint).ts +11 -6
  69. package/src/numeric (number).ts +11 -6
  70. package/src/numeric.ts +11 -6
  71. package/src/string (individual).ts +11 -6
  72. package/src/string.ts +11 -6
  73. package/src/symbol.ts +11 -6
package/src/collection.ts CHANGED
@@ -1,9 +1,16 @@
1
- /*******************************************************************************
2
- Copyright (c) 2023-2024. Jonathan Bédard ~ JóôòKiwi
1
+ //··························································
2
+ // Copyright (c) 2023-2025. Jonathan Bédard ~ JóôòKiwi
3
+ //
4
+ // This project is free to use.
5
+ // All the right is reserved to the author of this project.
6
+ // My projects:
7
+ // - https://github.com/joooKiwi/type
8
+ // - https://github.com/joooKiwi/lazy
9
+ // - https://github.com/joooKiwi/collection
10
+ // - https://github.com/joooKiwi/enumeration
11
+ //··························································
3
12
 
4
- This project is free to use.
5
- All the right is reserved to the author of this project.
6
- ******************************************************************************/
13
+ import type {UndefinedOr} from "./nullable"
7
14
 
8
15
  /**
9
16
  * A type-alias for an {@link ReadonlyArray Array} of a value
@@ -59,6 +66,112 @@ export type Set<T, > = ReadonlySet<T>
59
66
  */
60
67
  export type MutableSet<T, > = globalThis.Set<T>
61
68
 
69
+
70
+ /**
71
+ * An interface declaration for a {@link globalThis.WeakSet WeakSet} of a value that is immutable.
72
+ *
73
+ * The collection is holding {@link Object} and {@link Symbol}
74
+ * that is garbage-collectable.
75
+ * An object may be present at one time and not at the other due to being garbage collected.
76
+ *
77
+ * @supportedBy Chrome 36, Chrome Android 36
78
+ * @supportedBy Edge
79
+ * @supportedBy Firefox 34
80
+ * @supportedBy Opera 23
81
+ * @supportedBy Safari 9, Safari iOS 9
82
+ * @supportedBy Node.js 0.12.0
83
+ * @supportedBy Deno
84
+ * @by {@link https://developer.mozilla.org/docs/web/javascript/reference/global_objects/weakset/has/contributors.txt Mozilla Contributors}
85
+ * @by {@link https://creativecommons.org/licenses/by-sa/2.5 CC BY-SA 2.5}
86
+ */
87
+ export interface WeakSet<T extends WeakKey, > {
88
+
89
+ /**
90
+ * Indicate whenever the {@link value} exist or not in the current {@link WeakSet collection}
91
+ *
92
+ * @param value The value to test its presence
93
+ * @return Returns `true` if it exists otherwise `false`.
94
+ * Always returns `false` if the {@link value} is not an {@link Object} or a {@link https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Symbol#shared_symbols_in_the_global_symbol_registry non-registered symbol}
95
+ * @supportedBy Chrome 36, Chrome Android 36
96
+ * @supportedBy Edge
97
+ * @supportedBy Firefox 34
98
+ * @supportedBy Opera 23
99
+ * @supportedBy Safari 9, Safari iOS 9
100
+ * @supportedBy Node.js 0.12.0
101
+ * @supportedBy Deno
102
+ * @by {@link https://developer.mozilla.org/docs/web/javascript/reference/global_objects/weakset/has/contributors.txt Mozilla Contributors}
103
+ * @by {@link https://creativecommons.org/licenses/by-sa/2.5 CC BY-SA 2.5}
104
+ */
105
+ has(value: T,): boolean
106
+
107
+ /**
108
+ * Give an output for the call {@link Object.toString.call} giving [object WeakSet] instead of the general [object Object]
109
+ *
110
+ * @see https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Symbol/toStringTag
111
+ */
112
+ readonly [Symbol.toStringTag]: string
113
+
114
+ }
115
+
116
+ /**
117
+ * An interface declaration for a {@link globalThis.WeakSet WeakSet} of a value that is mutable
118
+ *
119
+ * The collection is holding {@link Object} and {@link Symbol}
120
+ * that is garbage-collectable.
121
+ * An object may be present at one time and not at the other due to being garbage collected.
122
+ *
123
+ * @supportedBy Chrome 36, Chrome Android 36
124
+ * @supportedBy Edge
125
+ * @supportedBy Firefox 34
126
+ * @supportedBy Opera 23
127
+ * @supportedBy Safari 9, Safari iOS 9
128
+ * @supportedBy Node.js 0.12.0
129
+ * @supportedBy Deno
130
+ * @by {@link https://developer.mozilla.org/docs/web/javascript/reference/global_objects/weakset/has/contributors.txt Mozilla Contributors}
131
+ * @by {@link https://creativecommons.org/licenses/by-sa/2.5 CC BY-SA 2.5}
132
+ */
133
+ export interface MutableWeakSet<T extends WeakKey, >
134
+ extends WeakSet<T> {
135
+
136
+ /**
137
+ * Add a new {@link value} to the end of the current {@link MutableWeakSet collection}
138
+ *
139
+ * @param value The value to add
140
+ * @return The current {@link MutableWeakSet} instance
141
+ * @throws TypeError The {@link value} is not an {@link Object} or a {@link https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Symbol#shared_symbols_in_the_global_symbol_registry non-registered symbol}
142
+ * @supportedBy Chrome 36, Chrome Android 36
143
+ * @supportedBy Edge
144
+ * @supportedBy Firefox 34
145
+ * @supportedBy Opera 23
146
+ * @supportedBy Safari 9, Safari iOS 9
147
+ * @supportedBy Node.js 0.12.0
148
+ * @supportedBy Deno
149
+ * @by {@link https://developer.mozilla.org/docs/web/javascript/reference/global_objects/weakset/has/contributors.txt Mozilla Contributors}
150
+ * @by {@link https://creativecommons.org/licenses/by-sa/2.5 CC BY-SA 2.5}
151
+ */
152
+ add(value: T,): this
153
+
154
+ /**
155
+ * Remove a {@link value} (if it exists) in the current {@link MutableWeakSet collection}
156
+ *
157
+ * @param value The value to possibly remove
158
+ * @return Returns `true` if the {@link value} has been removed successfully, otherwise `false`.
159
+ * Always returns `false` if the {@link value} is not an {@link Object} or a {@link https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Symbol#shared_symbols_in_the_global_symbol_registry non-registered symbol}
160
+ * @supportedBy Chrome 36, Chrome Android 36
161
+ * @supportedBy Edge
162
+ * @supportedBy Firefox 34
163
+ * @supportedBy Opera 23
164
+ * @supportedBy Safari 9, Safari iOS 9
165
+ * @supportedBy Node.js 0.12.0
166
+ * @supportedBy Deno
167
+ * @by {@link https://developer.mozilla.org/docs/web/javascript/reference/global_objects/weakset/has/contributors.txt Mozilla Contributors}
168
+ * @by {@link https://creativecommons.org/licenses/by-sa/2.5 CC BY-SA 2.5}
169
+ */
170
+ delete(value: T,): boolean
171
+
172
+ }
173
+
174
+
62
175
  /**
63
176
  * A type-alias for a {@link ReadonlyMap Map} of a key and a value
64
177
  *
@@ -151,7 +264,6 @@ export type MutableSet<T, > = globalThis.Set<T>
151
264
  * @see TypescriptSymbolTypescriptSymbolMap
152
265
  */
153
266
  export type Map<K, V, > = ReadonlyMap<K, V>
154
-
155
267
  /**
156
268
  * A type-alias for a {@link globalThis.Map MutableMap} of a key and a value
157
269
  *
@@ -244,3 +356,127 @@ export type Map<K, V, > = ReadonlyMap<K, V>
244
356
  * @see MutableTypescriptSymbolTypescriptSymbolMap
245
357
  */
246
358
  export type MutableMap<K, V, > = globalThis.Map<K, V>
359
+
360
+
361
+ /**
362
+ * An interface declaration for a {@link globalThis.WeakMap WeakMap} of a key-value pair that is immutable.
363
+ *
364
+ * The associative collection is holding a key {@link Object} and {@link Symbol}
365
+ * that is garbage-collectable.
366
+ * A key may be present at one time and not at the other due to being garbage collected.
367
+ *
368
+ * @supportedBy Chrome 36, Chrome Android 36
369
+ * @supportedBy Edge
370
+ * @supportedBy Firefox 6
371
+ * @supportedBy Opera 23
372
+ * @supportedBy Safari 8, Safari iOS 8
373
+ * @supportedBy Node.js 0.12.0
374
+ * @supportedBy Deno
375
+ * @by {@link https://developer.mozilla.org/docs/web/javascript/reference/global_objects/weakset/has/contributors.txt Mozilla Contributors}
376
+ * @by {@link https://creativecommons.org/licenses/by-sa/2.5 CC BY-SA 2.5}
377
+ */
378
+ export interface WeakMap<K extends WeakKey, V, > {
379
+
380
+ /**
381
+ * Retrieve the element associated to the {@link key} received in the {@link WeakMap associative collection}
382
+ *
383
+ * @param key The key to retrieve a possible value
384
+ * @return Returns the value present if it exists, otherwise `undefined`.
385
+ * Always returns `undefined` if the {@link value} is not an {@link Object} or a {@link https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Symbol#shared_symbols_in_the_global_symbol_registry non-registered symbol}
386
+ * @supportedBy Chrome 36, Chrome Android 36
387
+ * @supportedBy Edge
388
+ * @supportedBy Firefox 6
389
+ * @supportedBy Opera 23
390
+ * @supportedBy Safari 8, Safari iOS 8
391
+ * @supportedBy Node.js 0.12.0
392
+ * @supportedBy Deno
393
+ * @by {@link https://developer.mozilla.org/docs/web/javascript/reference/global_objects/weakset/has/contributors.txt Mozilla Contributors}
394
+ * @by {@link https://creativecommons.org/licenses/by-sa/2.5 CC BY-SA 2.5}
395
+ */
396
+ get(key: K,): UndefinedOr<V>
397
+
398
+ /**
399
+ * Indicate whenever the {@link key} has an existant value in the current {@link WeakMap associative collection}
400
+ *
401
+ * @param key The key to test its presence
402
+ * @return Returns `true` if it an element exists otherwise `false`.
403
+ * Always returns `false` if the {@link key} is not an {@link Object} or a {@link https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Symbol#shared_symbols_in_the_global_symbol_registry non-registered symbol}
404
+ * @supportedBy Chrome 36, Chrome Android 36
405
+ * @supportedBy Edge
406
+ * @supportedBy Firefox 6
407
+ * @supportedBy Opera 23
408
+ * @supportedBy Safari 8, Safari iOS 8
409
+ * @supportedBy Node.js 0.12.0
410
+ * @supportedBy Deno
411
+ * @by {@link https://developer.mozilla.org/docs/web/javascript/reference/global_objects/weakset/has/contributors.txt Mozilla Contributors}
412
+ * @by {@link https://creativecommons.org/licenses/by-sa/2.5 CC BY-SA 2.5}
413
+ */
414
+ has(key: K,): boolean
415
+
416
+ /**
417
+ * Give an output for the call {@link Object.toString.call} giving [object WeakMap] instead of the general [object Object]
418
+ *
419
+ * @see https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Symbol/toStringTag
420
+ */
421
+ readonly [Symbol.toStringTag]: string
422
+
423
+ }
424
+
425
+ /**
426
+ * An interface declaration for a {@link globalThis.WeakMap WeakMap} of a key-value pair that is mutable.
427
+ *
428
+ * The associative collection is holding a key {@link Object} and {@link Symbol}
429
+ * that is garbage-collectable.
430
+ * A key may be present at one time and not at the other due to being garbage collected.
431
+ *
432
+ * @supportedBy Chrome 36, Chrome Android 36
433
+ * @supportedBy Edge
434
+ * @supportedBy Firefox 6
435
+ * @supportedBy Opera 23
436
+ * @supportedBy Safari 8, Safari iOS 8
437
+ * @supportedBy Node.js 0.12.0
438
+ * @supportedBy Deno
439
+ * @by {@link https://developer.mozilla.org/docs/web/javascript/reference/global_objects/weakset/has/contributors.txt Mozilla Contributors}
440
+ * @by {@link https://creativecommons.org/licenses/by-sa/2.5 CC BY-SA 2.5}
441
+ */
442
+ export interface MutableWeakMap<K extends WeakKey, V, >
443
+ extends WeakMap<K, V> {
444
+
445
+ /**
446
+ * Add or change the {@link value} associated to the {@link key} received
447
+ * in the current {@link MutableWeakMap associative collection}
448
+ *
449
+ * @param key The key to add or update
450
+ * @param value The value to associate to the {@link key}
451
+ * @throws TypeError The {@link key} is not an {@link Object} or a {@link https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Symbol#shared_symbols_in_the_global_symbol_registry non-registered symbol}
452
+ * @supportedBy Chrome 36, Chrome Android 36
453
+ * @supportedBy Edge
454
+ * @supportedBy Firefox 6
455
+ * @supportedBy Opera 23
456
+ * @supportedBy Safari 8, Safari iOS 8
457
+ * @supportedBy Node.js 0.12.0
458
+ * @supportedBy Deno
459
+ * @by {@link https://developer.mozilla.org/docs/web/javascript/reference/global_objects/weakset/has/contributors.txt Mozilla Contributors}
460
+ * @by {@link https://creativecommons.org/licenses/by-sa/2.5 CC BY-SA 2.5}
461
+ */
462
+ set(key: K, value: V,): this
463
+
464
+ /**
465
+ * Remove a {@link key} (if it exists) in the current {@link MutableWeakMap associative collection}
466
+ *
467
+ * @param key The key to possibly remove
468
+ * @return Returns `true` if the {@link key} has been removed successfully, otherwise `false`.
469
+ * Always returns `false` if the {@link key} is not an {@link Object} or a {@link https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Symbol#shared_symbols_in_the_global_symbol_registry non-registered symbol}
470
+ * @supportedBy Chrome 36, Chrome Android 36
471
+ * @supportedBy Edge
472
+ * @supportedBy Firefox 6
473
+ * @supportedBy Opera 23
474
+ * @supportedBy Safari 8, Safari iOS 8
475
+ * @supportedBy Node.js 0.12.0
476
+ * @supportedBy Deno
477
+ * @by {@link https://developer.mozilla.org/docs/web/javascript/reference/global_objects/weakset/has/contributors.txt Mozilla Contributors}
478
+ * @by {@link https://creativecommons.org/licenses/by-sa/2.5 CC BY-SA 2.5}
479
+ */
480
+ delete(key: K,): boolean
481
+
482
+ }
package/src/empty.ts CHANGED
@@ -1,9 +1,14 @@
1
- /*******************************************************************************
2
- Copyright (c) 2023-2024. Jonathan Bédard ~ JóôòKiwi
3
-
4
- This project is free to use.
5
- All the right is reserved to the author of this project.
6
- ******************************************************************************/
1
+ //··························································
2
+ // Copyright (c) 2023-2025. Jonathan Bédard ~ JóôòKiwi
3
+ //
4
+ // This project is free to use.
5
+ // All the right is reserved to the author of this project.
6
+ // My projects:
7
+ // - https://github.com/joooKiwi/type
8
+ // - https://github.com/joooKiwi/lazy
9
+ // - https://github.com/joooKiwi/collection
10
+ // - https://github.com/joooKiwi/enumeration
11
+ //··························································
7
12
 
8
13
  /** A type-alias for an empty {@link String} */
9
14
  export type EmptyString = ""
@@ -24,14 +29,14 @@ export type EmptyMutableArray = []
24
29
  /**
25
30
  * A type-alias for an empty {@link ReadonlySet Set}
26
31
  *
27
- * @param T The {@link ReadonlySet Set} type (<i>{@code never} by default</i>)
32
+ * @param T The {@link ReadonlySet Set} type (<i><b>never</b> by default</i>)
28
33
  * @see EmptyMutableSet
29
34
  */
30
35
  export type EmptySet<T = never, > = ReadonlySet<T>
31
36
  /**
32
37
  * A type-alias for an empty {@link Set MutableSet}
33
38
  *
34
- * @param T The {@link Set MutableSet} type (<i>{@code never} by default</i>)
39
+ * @param T The {@link Set MutableSet} type (<i><b>never</b> by default</i>)
35
40
  * @see EmptySet
36
41
  */
37
42
  export type EmptyMutableSet<T = never, > = Set<T>
@@ -39,51 +44,51 @@ export type EmptyMutableSet<T = never, > = Set<T>
39
44
  /**
40
45
  * A type-alias for an empty {@link WeakSet}
41
46
  *
42
- * @param T The {@link WeakSet} type (<i>{@link WeakKey} by default</i>)
47
+ * @param T The {@link WeakSet} type (<i><b>never</b> by default</i>)
43
48
  * @see EmptyMutableWeakSet
44
49
  */
45
- export type EmptyWeakSet<T extends WeakKey = WeakKey, > = Readonly<WeakSet<T>>
50
+ export type EmptyWeakSet<T extends WeakKey = never, > = Readonly<WeakSet<T>>
46
51
  /**
47
52
  * A type-alias for an empty {@link WeakSet MutableWeakSet}
48
53
  *
49
- * @param T The {@link WeakSet MutableWeakSet} type (<i>{@link WeakKey} by default</i>)
54
+ * @param T The {@link WeakSet MutableWeakSet} type (<i><b>never</b> by default</i>)
50
55
  * @see EmptyWeakSet
51
56
  */
52
- export type EmptyMutableWeakSet<T extends WeakKey = WeakKey, > = WeakSet<T>
57
+ export type EmptyMutableWeakSet<T extends WeakKey = never, > = WeakSet<T>
53
58
 
54
59
  /**
55
60
  * A type-alias for an empty {@link ReadonlyMap Map}
56
61
  *
57
- * @param K The {@link ReadonlyMap Map} key type (<i>{@code unknown} by default</i>)
58
- * @param V The {@link ReadonlyMap Map} value type (<i>{@code never} by default</i>)
62
+ * @param K The {@link ReadonlyMap Map} key type (<i><b>never</b> by default</i>)
63
+ * @param V The {@link ReadonlyMap Map} value type (<i><b>never</b> by default</i>)
59
64
  * @see EmptyMutableMap
60
65
  */
61
- export type EmptyMap<K = unknown, V = never, > = ReadonlyMap<K, V>
66
+ export type EmptyMap<K = never, V = never, > = ReadonlyMap<K, V>
62
67
  /**
63
68
  * A type-alias for an empty {@link Map MutableMap}
64
69
  *
65
- * @param K The {@link Map MutableMap} key type (<i>{@code unknown} by default</i>)
66
- * @param V The {@link Map MutableMap} value type (<i>{@code never} by default</i>)
70
+ * @param K The {@link Map MutableMap} key type (<i><b>never</b> by default</i>)
71
+ * @param V The {@link Map MutableMap} value type (<i><b>never</b> by default</i>)
67
72
  * @see EmptyMap
68
73
  */
69
- export type EmptyMutableMap<K = unknown, V = never, > = Map<K, V>
74
+ export type EmptyMutableMap<K = never, V = never, > = Map<K, V>
70
75
 
71
76
  /**
72
77
  * A type-alias for an empty {@link WeakMap}
73
78
  *
74
- * @param K The {@link WeakMap} key type (<i>{@link WeakKey} by default</i>)
75
- * @param V The {@link WeakMap} value type (<i>{@code never} by default</i>)
79
+ * @param K The {@link WeakMap} key type (<i><b>never</b> by default</i>)
80
+ * @param V The {@link WeakMap} value type (<i><b>never</b> by default</i>)
76
81
  * @see EmptyMutableWeakMap
77
82
  */
78
- export type EmptyWeakMap<K extends WeakKey = WeakKey, V = never, > = Readonly<WeakMap<K, V>>
83
+ export type EmptyWeakMap<K extends WeakKey = never, V = never, > = Readonly<WeakMap<K, V>>
79
84
  /**
80
85
  * A type-alias for an empty {@link WeakMap MutableWeakMap}
81
86
  *
82
- * @param K The {@link WeakMap MutableWeakMap} key type (<i>{@link WeakKey} by default</i>)
83
- * @param V The {@link WeakMap MutableWeakMap} value type (<i>{@code never} by default</i>)
87
+ * @param K The {@link WeakMap MutableWeakMap} key type (<i><b>never</b> by default</i>)
88
+ * @param V The {@link WeakMap MutableWeakMap} value type (<i><b>never</b> by default</i>)
84
89
  * @see EmptyWeakMap
85
90
  */
86
- export type EmptyMutableWeakMap<K extends WeakKey = WeakKey, V = never, > = WeakMap<K, V>
91
+ export type EmptyMutableWeakMap<K extends WeakKey = never, V = never, > = WeakMap<K, V>
87
92
 
88
93
  /**
89
94
  * A type-alias for an empty {@link Object}
package/src/index.ts CHANGED
@@ -1,9 +1,14 @@
1
- /*******************************************************************************
2
- Copyright (c) 2023-2024. Jonathan Bédard ~ JóôòKiwi
3
-
4
- This project is free to use.
5
- All the right is reserved to the author of this project.
6
- ******************************************************************************/
1
+ //··························································
2
+ // Copyright (c) 2023-2025. Jonathan Bédard ~ JóôòKiwi
3
+ //
4
+ // This project is free to use.
5
+ // All the right is reserved to the author of this project.
6
+ // My projects:
7
+ // - https://github.com/joooKiwi/type
8
+ // - https://github.com/joooKiwi/lazy
9
+ // - https://github.com/joooKiwi/collection
10
+ // - https://github.com/joooKiwi/enumeration
11
+ //··························································
7
12
 
8
13
  export type * from "./boolean"
9
14
  export type * from "./boolean (false)"
package/src/mixed.ts CHANGED
@@ -1,9 +1,14 @@
1
- /*******************************************************************************
2
- Copyright (c) 2023-2024. Jonathan Bédard ~ JóôòKiwi
3
-
4
- This project is free to use.
5
- All the right is reserved to the author of this project.
6
- ******************************************************************************/
1
+ //··························································
2
+ // Copyright (c) 2023-2025. Jonathan Bédard ~ JóôòKiwi
3
+ //
4
+ // This project is free to use.
5
+ // All the right is reserved to the author of this project.
6
+ // My projects:
7
+ // - https://github.com/joooKiwi/type
8
+ // - https://github.com/joooKiwi/lazy
9
+ // - https://github.com/joooKiwi/collection
10
+ // - https://github.com/joooKiwi/enumeration
11
+ //··························································
7
12
 
8
13
  //#region -------------------- mixed (direct - double) --------------------
9
14
 
package/src/nullable.ts CHANGED
@@ -1,9 +1,14 @@
1
- /*******************************************************************************
2
- Copyright (c) 2023-2024. Jonathan Bédard ~ JóôòKiwi
3
-
4
- This project is free to use.
5
- All the right is reserved to the author of this project.
6
- ******************************************************************************/
1
+ //··························································
2
+ // Copyright (c) 2023-2025. Jonathan Bédard ~ JóôòKiwi
3
+ //
4
+ // This project is free to use.
5
+ // All the right is reserved to the author of this project.
6
+ // My projects:
7
+ // - https://github.com/joooKiwi/type
8
+ // - https://github.com/joooKiwi/lazy
9
+ // - https://github.com/joooKiwi/collection
10
+ // - https://github.com/joooKiwi/enumeration
11
+ //··························································
7
12
 
8
13
  import type {Numeric} from "./numeric"
9
14
  import type {Zero, ZeroBigInt, ZeroNumber} from "./numeric (0)"
@@ -1,9 +1,14 @@
1
- /*******************************************************************************
2
- Copyright (c) 2023-2024. Jonathan Bédard ~ JóôòKiwi
3
-
4
- This project is free to use.
5
- All the right is reserved to the author of this project.
6
- ******************************************************************************/
1
+ //··························································
2
+ // Copyright (c) 2023-2025. Jonathan Bédard ~ JóôòKiwi
3
+ //
4
+ // This project is free to use.
5
+ // All the right is reserved to the author of this project.
6
+ // My projects:
7
+ // - https://github.com/joooKiwi/type
8
+ // - https://github.com/joooKiwi/lazy
9
+ // - https://github.com/joooKiwi/collection
10
+ // - https://github.com/joooKiwi/enumeration
11
+ //··························································
7
12
 
8
13
  /**
9
14
  * A type-alias for <b>-1</b> (as a {@link Number} or a {@link BigInt})
@@ -1,9 +1,14 @@
1
- /*******************************************************************************
2
- Copyright (c) 2023-2024. Jonathan Bédard ~ JóôòKiwi
3
-
4
- This project is free to use.
5
- All the right is reserved to the author of this project.
6
- ******************************************************************************/
1
+ //··························································
2
+ // Copyright (c) 2023-2025. Jonathan Bédard ~ JóôòKiwi
3
+ //
4
+ // This project is free to use.
5
+ // All the right is reserved to the author of this project.
6
+ // My projects:
7
+ // - https://github.com/joooKiwi/type
8
+ // - https://github.com/joooKiwi/lazy
9
+ // - https://github.com/joooKiwi/collection
10
+ // - https://github.com/joooKiwi/enumeration
11
+ //··························································
7
12
 
8
13
  /**
9
14
  * A type-alias for <b>0</b> (as a {@link Number} or a {@link BigInt})
@@ -1,9 +1,14 @@
1
- /*******************************************************************************
2
- Copyright (c) 2023-2024. Jonathan Bédard ~ JóôòKiwi
3
-
4
- This project is free to use.
5
- All the right is reserved to the author of this project.
6
- ******************************************************************************/
1
+ //··························································
2
+ // Copyright (c) 2023-2025. Jonathan Bédard ~ JóôòKiwi
3
+ //
4
+ // This project is free to use.
5
+ // All the right is reserved to the author of this project.
6
+ // My projects:
7
+ // - https://github.com/joooKiwi/type
8
+ // - https://github.com/joooKiwi/lazy
9
+ // - https://github.com/joooKiwi/collection
10
+ // - https://github.com/joooKiwi/enumeration
11
+ //··························································
7
12
 
8
13
  /**
9
14
  * A type-alias for <b>1</b> (as a {@link Number} or a {@link BigInt})
@@ -1,9 +1,14 @@
1
- /*******************************************************************************
2
- Copyright (c) 2023-2024. Jonathan Bédard ~ JóôòKiwi
3
-
4
- This project is free to use.
5
- All the right is reserved to the author of this project.
6
- ******************************************************************************/
1
+ //··························································
2
+ // Copyright (c) 2023-2025. Jonathan Bédard ~ JóôòKiwi
3
+ //
4
+ // This project is free to use.
5
+ // All the right is reserved to the author of this project.
6
+ // My projects:
7
+ // - https://github.com/joooKiwi/type
8
+ // - https://github.com/joooKiwi/lazy
9
+ // - https://github.com/joooKiwi/collection
10
+ // - https://github.com/joooKiwi/enumeration
11
+ //··························································
7
12
 
8
13
  /**
9
14
  * A type-alias for <b>2</b> (as a {@link Number} or a {@link BigInt})
@@ -1,9 +1,14 @@
1
- /*******************************************************************************
2
- Copyright (c) 2023-2024. Jonathan Bédard ~ JóôòKiwi
3
-
4
- This project is free to use.
5
- All the right is reserved to the author of this project.
6
- ******************************************************************************/
1
+ //··························································
2
+ // Copyright (c) 2023-2025. Jonathan Bédard ~ JóôòKiwi
3
+ //
4
+ // This project is free to use.
5
+ // All the right is reserved to the author of this project.
6
+ // My projects:
7
+ // - https://github.com/joooKiwi/type
8
+ // - https://github.com/joooKiwi/lazy
9
+ // - https://github.com/joooKiwi/collection
10
+ // - https://github.com/joooKiwi/enumeration
11
+ //··························································
7
12
 
8
13
  /** A type-alias for a {@link BigInt}
9
14
  * in a {@link String} template
@@ -1,9 +1,14 @@
1
- /*******************************************************************************
2
- Copyright (c) 2023-2024. Jonathan Bédard ~ JóôòKiwi
3
-
4
- This project is free to use.
5
- All the right is reserved to the author of this project.
6
- ******************************************************************************/
1
+ //··························································
2
+ // Copyright (c) 2023-2025. Jonathan Bédard ~ JóôòKiwi
3
+ //
4
+ // This project is free to use.
5
+ // All the right is reserved to the author of this project.
6
+ // My projects:
7
+ // - https://github.com/joooKiwi/type
8
+ // - https://github.com/joooKiwi/lazy
9
+ // - https://github.com/joooKiwi/collection
10
+ // - https://github.com/joooKiwi/enumeration
11
+ //··························································
7
12
 
8
13
  /**
9
14
  * A type-alias for a {@link Number}
package/src/numeric.ts CHANGED
@@ -1,9 +1,14 @@
1
- /*******************************************************************************
2
- Copyright (c) 2023-2024. Jonathan Bédard ~ JóôòKiwi
3
-
4
- This project is free to use.
5
- All the right is reserved to the author of this project.
6
- ******************************************************************************/
1
+ //··························································
2
+ // Copyright (c) 2023-2025. Jonathan Bédard ~ JóôòKiwi
3
+ //
4
+ // This project is free to use.
5
+ // All the right is reserved to the author of this project.
6
+ // My projects:
7
+ // - https://github.com/joooKiwi/type
8
+ // - https://github.com/joooKiwi/lazy
9
+ // - https://github.com/joooKiwi/collection
10
+ // - https://github.com/joooKiwi/enumeration
11
+ //··························································
7
12
 
8
13
  /** A type-alias for a {@link Number} or a {@link BigInt} as a primitive */
9
14
  export type Numeric<T extends | number | bigint = | number | bigint, > = T
@@ -1,9 +1,14 @@
1
- /*******************************************************************************
2
- Copyright (c) 2023-2024. Jonathan Bédard ~ JóôòKiwi
3
-
4
- This project is free to use.
5
- All the right is reserved to the author of this project.
6
- ******************************************************************************/
1
+ //··························································
2
+ // Copyright (c) 2023-2025. Jonathan Bédard ~ JóôòKiwi
3
+ //
4
+ // This project is free to use.
5
+ // All the right is reserved to the author of this project.
6
+ // My projects:
7
+ // - https://github.com/joooKiwi/type
8
+ // - https://github.com/joooKiwi/lazy
9
+ // - https://github.com/joooKiwi/collection
10
+ // - https://github.com/joooKiwi/enumeration
11
+ //··························································
7
12
 
8
13
  /** A type-alias for the {@link Boolean} <b>true</b> as a {@link String} */
9
14
  export type TrueString = "true"
package/src/string.ts CHANGED
@@ -1,9 +1,14 @@
1
- /*******************************************************************************
2
- Copyright (c) 2023-2024. Jonathan Bédard ~ JóôòKiwi
3
-
4
- This project is free to use.
5
- All the right is reserved to the author of this project.
6
- ******************************************************************************/
1
+ //··························································
2
+ // Copyright (c) 2023-2025. Jonathan Bédard ~ JóôòKiwi
3
+ //
4
+ // This project is free to use.
5
+ // All the right is reserved to the author of this project.
6
+ // My projects:
7
+ // - https://github.com/joooKiwi/type
8
+ // - https://github.com/joooKiwi/lazy
9
+ // - https://github.com/joooKiwi/collection
10
+ // - https://github.com/joooKiwi/enumeration
11
+ //··························································
7
12
 
8
13
  /**
9
14
  * A type-alias for a value