type-plus 7.3.1 → 7.5.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 (376) hide show
  1. package/README.md +146 -183
  2. package/cjs/any/any_type.d.ts +8 -8
  3. package/cjs/any/any_type.d.ts.map +1 -1
  4. package/cjs/array/array.at.d.ts +3 -1
  5. package/cjs/array/array.at.d.ts.map +1 -1
  6. package/cjs/array/array.entries.d.ts +4 -3
  7. package/cjs/array/array.entries.d.ts.map +1 -1
  8. package/cjs/array/array.find_last.d.ts +3 -1
  9. package/cjs/array/array.find_last.d.ts.map +1 -1
  10. package/cjs/array/array.some.d.ts +1 -1
  11. package/cjs/array/array.some.d.ts.map +1 -1
  12. package/cjs/array/array_plus.common_prop_keys.d.ts +27 -0
  13. package/cjs/array/array_plus.common_prop_keys.d.ts.map +1 -0
  14. package/cjs/array/array_plus.common_prop_keys.js +3 -0
  15. package/cjs/array/array_plus.common_prop_keys.js.map +1 -0
  16. package/cjs/array/{array.concat.d.ts → array_plus.concat.d.ts} +4 -1
  17. package/cjs/array/array_plus.concat.d.ts.map +1 -0
  18. package/cjs/array/array_plus.concat.js +3 -0
  19. package/cjs/array/array_plus.concat.js.map +1 -0
  20. package/cjs/array/array_plus.d.ts +7 -3
  21. package/cjs/array/array_plus.d.ts.map +1 -1
  22. package/cjs/array/array_plus.drop_match.d.ts +4 -0
  23. package/cjs/array/array_plus.drop_match.d.ts.map +1 -0
  24. package/cjs/array/array_plus.drop_match.js +3 -0
  25. package/cjs/array/array_plus.drop_match.js.map +1 -0
  26. package/cjs/array/array_plus.element_match.d.ts +44 -0
  27. package/cjs/array/array_plus.element_match.d.ts.map +1 -0
  28. package/cjs/array/array_plus.element_match.js +3 -0
  29. package/cjs/array/array_plus.element_match.js.map +1 -0
  30. package/cjs/array/array_plus.filter.d.ts +2 -0
  31. package/cjs/array/array_plus.filter.d.ts.map +1 -0
  32. package/cjs/array/array_plus.filter.js +3 -0
  33. package/cjs/array/array_plus.filter.js.map +1 -0
  34. package/cjs/array/array_plus.find.d.ts +57 -0
  35. package/cjs/array/array_plus.find.d.ts.map +1 -0
  36. package/cjs/array/array_plus.find.js +3 -0
  37. package/cjs/array/array_plus.find.js.map +1 -0
  38. package/cjs/array/array_plus.pad_start.d.ts +5 -0
  39. package/cjs/array/array_plus.pad_start.d.ts.map +1 -0
  40. package/cjs/array/array_plus.pad_start.js +3 -0
  41. package/cjs/array/array_plus.pad_start.js.map +1 -0
  42. package/cjs/array/array_type.d.ts +30 -12
  43. package/cjs/array/array_type.d.ts.map +1 -1
  44. package/cjs/array/filter.d.ts +24 -4
  45. package/cjs/array/filter.d.ts.map +1 -1
  46. package/cjs/array/find_first.d.ts +62 -0
  47. package/cjs/array/find_first.d.ts.map +1 -0
  48. package/cjs/array/{array.find.js → find_first.js} +1 -1
  49. package/cjs/array/find_first.js.map +1 -0
  50. package/cjs/array/head.d.ts +30 -1
  51. package/cjs/array/head.d.ts.map +1 -1
  52. package/cjs/array/intersect_of_props.d.ts +5 -3
  53. package/cjs/array/intersect_of_props.d.ts.map +1 -1
  54. package/cjs/array/last.d.ts +27 -2
  55. package/cjs/array/last.d.ts.map +1 -1
  56. package/cjs/array/literal_array.d.ts +5 -0
  57. package/cjs/array/literal_array.d.ts.map +1 -1
  58. package/cjs/array/literal_array.js +5 -0
  59. package/cjs/array/literal_array.js.map +1 -1
  60. package/cjs/array/pad_start.d.ts +5 -5
  61. package/cjs/array/pad_start.d.ts.map +1 -1
  62. package/cjs/array/reduce_while.d.ts +6 -0
  63. package/cjs/array/reduce_while.d.ts.map +1 -1
  64. package/cjs/array/reduce_while.js +6 -0
  65. package/cjs/array/reduce_while.js.map +1 -1
  66. package/cjs/array/reverse.d.ts +5 -0
  67. package/cjs/array/reverse.d.ts.map +1 -1
  68. package/cjs/array/union_of_props.d.ts +1 -1
  69. package/cjs/array/union_of_props.d.ts.map +1 -1
  70. package/cjs/assertion/assert_type.d.ts +4 -1
  71. package/cjs/assertion/assert_type.d.ts.map +1 -1
  72. package/cjs/assertion/assert_type.js.map +1 -1
  73. package/cjs/functional/compose.d.ts +2 -1
  74. package/cjs/functional/compose.d.ts.map +1 -1
  75. package/cjs/functional/compose.js.map +1 -1
  76. package/cjs/functional/context.d.ts.map +1 -1
  77. package/cjs/index.d.ts +22 -3
  78. package/cjs/index.d.ts.map +1 -1
  79. package/cjs/index.js +9 -3
  80. package/cjs/index.js.map +1 -1
  81. package/cjs/math/numeric_struct.d.ts +1 -1
  82. package/cjs/math/numeric_struct.d.ts.map +1 -1
  83. package/cjs/mix_types/any_or_never_type.d.ts +1 -1
  84. package/cjs/never/never_type.d.ts +11 -0
  85. package/cjs/never/never_type.d.ts.map +1 -1
  86. package/cjs/nodejs/isNodeError.d.ts.map +1 -1
  87. package/cjs/nominal/brand.d.ts.map +1 -1
  88. package/cjs/nominal/flavor.d.ts.map +1 -1
  89. package/cjs/object/index.d.ts +0 -1
  90. package/cjs/object/index.d.ts.map +1 -1
  91. package/cjs/object/index.js.map +1 -1
  92. package/cjs/testing/test_type.d.ts +277 -233
  93. package/cjs/testing/test_type.d.ts.map +1 -1
  94. package/cjs/testing/test_type.js.map +1 -1
  95. package/cjs/tuple/common_prop_keys.d.ts +34 -0
  96. package/cjs/tuple/common_prop_keys.d.ts.map +1 -0
  97. package/cjs/tuple/common_prop_keys.js.map +1 -0
  98. package/cjs/tuple/create_tuple.d.ts.map +1 -1
  99. package/cjs/tuple/drop.d.ts +91 -0
  100. package/cjs/tuple/drop.d.ts.map +1 -0
  101. package/cjs/{array → tuple}/drop.js +3 -1
  102. package/cjs/tuple/drop.js.map +1 -0
  103. package/{esm/array → cjs/tuple}/tail.d.ts +1 -1
  104. package/cjs/{array → tuple}/tail.d.ts.map +1 -1
  105. package/cjs/{array → tuple}/tail.js.map +1 -1
  106. package/cjs/tuple/tuple_plus.common_prop_keys.d.ts +28 -0
  107. package/cjs/tuple/tuple_plus.common_prop_keys.d.ts.map +1 -0
  108. package/cjs/tuple/tuple_plus.common_prop_keys.js +3 -0
  109. package/cjs/tuple/tuple_plus.common_prop_keys.js.map +1 -0
  110. package/cjs/tuple/tuple_plus.d.ts +5 -1
  111. package/cjs/tuple/tuple_plus.d.ts.map +1 -1
  112. package/cjs/tuple/tuple_plus.drop_match.d.ts +6 -0
  113. package/cjs/tuple/tuple_plus.drop_match.d.ts.map +1 -0
  114. package/cjs/tuple/tuple_plus.drop_match.js +3 -0
  115. package/cjs/tuple/tuple_plus.drop_match.js.map +1 -0
  116. package/cjs/tuple/tuple_plus.filter.d.ts +13 -0
  117. package/cjs/tuple/tuple_plus.filter.d.ts.map +1 -0
  118. package/cjs/tuple/tuple_plus.filter.js +3 -0
  119. package/cjs/tuple/tuple_plus.filter.js.map +1 -0
  120. package/cjs/tuple/tuple_plus.find.d.ts +64 -0
  121. package/cjs/tuple/tuple_plus.find.d.ts.map +1 -0
  122. package/cjs/tuple/tuple_plus.find.js +3 -0
  123. package/cjs/tuple/tuple_plus.find.js.map +1 -0
  124. package/cjs/tuple/tuple_plus.js +0 -15
  125. package/cjs/tuple/tuple_plus.js.map +1 -1
  126. package/cjs/tuple/tuple_plus.pad_start.d.ts +11 -5
  127. package/cjs/tuple/tuple_plus.pad_start.d.ts.map +1 -1
  128. package/cjs/tuple/tuple_type.d.ts +41 -23
  129. package/cjs/tuple/tuple_type.d.ts.map +1 -1
  130. package/cjs/union/union.d.ts +33 -0
  131. package/cjs/union/union.d.ts.map +1 -0
  132. package/cjs/{array/array.concat.js → union/union.js} +1 -1
  133. package/cjs/union/union.js.map +1 -0
  134. package/cjs/unknown/unknown_type.d.ts +12 -0
  135. package/cjs/unknown/unknown_type.d.ts.map +1 -1
  136. package/cjs/utils/options.d.ts +10 -0
  137. package/cjs/utils/options.d.ts.map +1 -0
  138. package/cjs/utils/options.js +3 -0
  139. package/cjs/utils/options.js.map +1 -0
  140. package/esm/any/any_type.d.ts +8 -8
  141. package/esm/any/any_type.d.ts.map +1 -1
  142. package/esm/array/array.at.d.ts +3 -1
  143. package/esm/array/array.at.d.ts.map +1 -1
  144. package/esm/array/array.entries.d.ts +4 -3
  145. package/esm/array/array.entries.d.ts.map +1 -1
  146. package/esm/array/array.find_last.d.ts +3 -1
  147. package/esm/array/array.find_last.d.ts.map +1 -1
  148. package/esm/array/array.some.d.ts +1 -1
  149. package/esm/array/array.some.d.ts.map +1 -1
  150. package/esm/array/array_plus.common_prop_keys.d.ts +27 -0
  151. package/esm/array/array_plus.common_prop_keys.d.ts.map +1 -0
  152. package/esm/array/array_plus.common_prop_keys.js +2 -0
  153. package/esm/array/array_plus.common_prop_keys.js.map +1 -0
  154. package/esm/array/{array.concat.d.ts → array_plus.concat.d.ts} +4 -1
  155. package/esm/array/array_plus.concat.d.ts.map +1 -0
  156. package/esm/array/array_plus.concat.js +2 -0
  157. package/esm/array/array_plus.concat.js.map +1 -0
  158. package/esm/array/array_plus.d.ts +7 -3
  159. package/esm/array/array_plus.d.ts.map +1 -1
  160. package/esm/array/array_plus.drop_match.d.ts +4 -0
  161. package/esm/array/array_plus.drop_match.d.ts.map +1 -0
  162. package/esm/array/array_plus.drop_match.js +2 -0
  163. package/esm/array/array_plus.drop_match.js.map +1 -0
  164. package/esm/array/array_plus.element_match.d.ts +44 -0
  165. package/esm/array/array_plus.element_match.d.ts.map +1 -0
  166. package/esm/array/array_plus.element_match.js +2 -0
  167. package/esm/array/array_plus.element_match.js.map +1 -0
  168. package/esm/array/array_plus.filter.d.ts +2 -0
  169. package/esm/array/array_plus.filter.d.ts.map +1 -0
  170. package/esm/array/array_plus.filter.js +2 -0
  171. package/esm/array/array_plus.filter.js.map +1 -0
  172. package/esm/array/array_plus.find.d.ts +57 -0
  173. package/esm/array/array_plus.find.d.ts.map +1 -0
  174. package/esm/array/array_plus.find.js +2 -0
  175. package/esm/array/array_plus.find.js.map +1 -0
  176. package/esm/array/array_plus.pad_start.d.ts +5 -0
  177. package/esm/array/array_plus.pad_start.d.ts.map +1 -0
  178. package/esm/array/array_plus.pad_start.js +2 -0
  179. package/esm/array/array_plus.pad_start.js.map +1 -0
  180. package/esm/array/array_type.d.ts +30 -12
  181. package/esm/array/array_type.d.ts.map +1 -1
  182. package/esm/array/filter.d.ts +24 -4
  183. package/esm/array/filter.d.ts.map +1 -1
  184. package/esm/array/find_first.d.ts +62 -0
  185. package/esm/array/find_first.d.ts.map +1 -0
  186. package/esm/array/find_first.js +2 -0
  187. package/esm/array/find_first.js.map +1 -0
  188. package/esm/array/head.d.ts +30 -1
  189. package/esm/array/head.d.ts.map +1 -1
  190. package/esm/array/intersect_of_props.d.ts +5 -3
  191. package/esm/array/intersect_of_props.d.ts.map +1 -1
  192. package/esm/array/last.d.ts +27 -2
  193. package/esm/array/last.d.ts.map +1 -1
  194. package/esm/array/literal_array.d.ts +5 -0
  195. package/esm/array/literal_array.d.ts.map +1 -1
  196. package/esm/array/literal_array.js +5 -0
  197. package/esm/array/literal_array.js.map +1 -1
  198. package/esm/array/pad_start.d.ts +5 -5
  199. package/esm/array/pad_start.d.ts.map +1 -1
  200. package/esm/array/reduce_while.d.ts +6 -0
  201. package/esm/array/reduce_while.d.ts.map +1 -1
  202. package/esm/array/reduce_while.js +6 -0
  203. package/esm/array/reduce_while.js.map +1 -1
  204. package/esm/array/reverse.d.ts +5 -0
  205. package/esm/array/reverse.d.ts.map +1 -1
  206. package/esm/array/union_of_props.d.ts +1 -1
  207. package/esm/array/union_of_props.d.ts.map +1 -1
  208. package/esm/assertion/assert_type.d.ts +4 -1
  209. package/esm/assertion/assert_type.d.ts.map +1 -1
  210. package/esm/assertion/assert_type.js.map +1 -1
  211. package/esm/functional/compose.d.ts +2 -1
  212. package/esm/functional/compose.d.ts.map +1 -1
  213. package/esm/functional/compose.js.map +1 -1
  214. package/esm/functional/context.d.ts.map +1 -1
  215. package/esm/index.d.ts +22 -3
  216. package/esm/index.d.ts.map +1 -1
  217. package/esm/index.js +4 -2
  218. package/esm/index.js.map +1 -1
  219. package/esm/math/numeric_struct.d.ts +1 -1
  220. package/esm/math/numeric_struct.d.ts.map +1 -1
  221. package/esm/mix_types/any_or_never_type.d.ts +1 -1
  222. package/esm/never/never_type.d.ts +11 -0
  223. package/esm/never/never_type.d.ts.map +1 -1
  224. package/esm/nodejs/isNodeError.d.ts.map +1 -1
  225. package/esm/nominal/brand.d.ts.map +1 -1
  226. package/esm/nominal/flavor.d.ts.map +1 -1
  227. package/esm/object/index.d.ts +0 -1
  228. package/esm/object/index.d.ts.map +1 -1
  229. package/esm/object/index.js.map +1 -1
  230. package/esm/testing/test_type.d.ts +277 -233
  231. package/esm/testing/test_type.d.ts.map +1 -1
  232. package/esm/testing/test_type.js.map +1 -1
  233. package/esm/tuple/common_prop_keys.d.ts +34 -0
  234. package/esm/tuple/common_prop_keys.d.ts.map +1 -0
  235. package/esm/tuple/common_prop_keys.js.map +1 -0
  236. package/esm/tuple/create_tuple.d.ts.map +1 -1
  237. package/esm/tuple/drop.d.ts +91 -0
  238. package/esm/tuple/drop.d.ts.map +1 -0
  239. package/esm/tuple/drop.js +9 -0
  240. package/esm/tuple/drop.js.map +1 -0
  241. package/{cjs/array → esm/tuple}/tail.d.ts +1 -1
  242. package/esm/{array → tuple}/tail.d.ts.map +1 -1
  243. package/esm/{array → tuple}/tail.js.map +1 -1
  244. package/esm/tuple/tuple_plus.common_prop_keys.d.ts +28 -0
  245. package/esm/tuple/tuple_plus.common_prop_keys.d.ts.map +1 -0
  246. package/esm/tuple/tuple_plus.common_prop_keys.js +2 -0
  247. package/esm/tuple/tuple_plus.common_prop_keys.js.map +1 -0
  248. package/esm/tuple/tuple_plus.d.ts +5 -1
  249. package/esm/tuple/tuple_plus.d.ts.map +1 -1
  250. package/esm/tuple/tuple_plus.drop_match.d.ts +6 -0
  251. package/esm/tuple/tuple_plus.drop_match.d.ts.map +1 -0
  252. package/esm/tuple/tuple_plus.drop_match.js +2 -0
  253. package/esm/tuple/tuple_plus.drop_match.js.map +1 -0
  254. package/esm/tuple/tuple_plus.filter.d.ts +13 -0
  255. package/esm/tuple/tuple_plus.filter.d.ts.map +1 -0
  256. package/esm/tuple/tuple_plus.filter.js +2 -0
  257. package/esm/tuple/tuple_plus.filter.js.map +1 -0
  258. package/esm/tuple/tuple_plus.find.d.ts +64 -0
  259. package/esm/tuple/tuple_plus.find.d.ts.map +1 -0
  260. package/esm/tuple/tuple_plus.find.js +2 -0
  261. package/esm/tuple/tuple_plus.find.js.map +1 -0
  262. package/esm/tuple/tuple_plus.js +1 -1
  263. package/esm/tuple/tuple_plus.js.map +1 -1
  264. package/esm/tuple/tuple_plus.pad_start.d.ts +11 -5
  265. package/esm/tuple/tuple_plus.pad_start.d.ts.map +1 -1
  266. package/esm/tuple/tuple_type.d.ts +41 -23
  267. package/esm/tuple/tuple_type.d.ts.map +1 -1
  268. package/esm/union/union.d.ts +33 -0
  269. package/esm/union/union.d.ts.map +1 -0
  270. package/esm/union/union.js +2 -0
  271. package/esm/union/union.js.map +1 -0
  272. package/esm/unknown/unknown_type.d.ts +12 -0
  273. package/esm/unknown/unknown_type.d.ts.map +1 -1
  274. package/esm/utils/options.d.ts +10 -0
  275. package/esm/utils/options.d.ts.map +1 -0
  276. package/esm/utils/options.js +2 -0
  277. package/esm/utils/options.js.map +1 -0
  278. package/package.json +12 -9
  279. package/ts/any/any_type.ts +8 -9
  280. package/ts/any/readme.md +71 -4
  281. package/ts/array/array.at.ts +3 -1
  282. package/ts/array/array.entries.ts +4 -2
  283. package/ts/array/array.find_last.ts +3 -1
  284. package/ts/array/array.some.ts +1 -1
  285. package/ts/array/array_plus.common_prop_keys.ts +35 -0
  286. package/ts/array/{array.concat.ts → array_plus.concat.ts} +3 -0
  287. package/ts/array/array_plus.drop_match.ts +16 -0
  288. package/ts/array/array_plus.element_match.ts +61 -0
  289. package/ts/array/array_plus.filter.ts +5 -0
  290. package/ts/array/array_plus.find.ts +71 -0
  291. package/ts/array/array_plus.pad_start.ts +13 -0
  292. package/ts/array/array_plus.ts +7 -3
  293. package/ts/array/array_type.ts +30 -12
  294. package/ts/array/filter.ts +27 -22
  295. package/ts/array/find_first.ts +71 -0
  296. package/ts/array/head.ts +40 -1
  297. package/ts/array/intersect_of_props.ts +7 -3
  298. package/ts/array/last.ts +36 -2
  299. package/ts/array/literal_array.ts +5 -0
  300. package/ts/array/pad_start.ts +6 -10
  301. package/ts/array/readme.md +297 -32
  302. package/ts/array/reduce_while.ts +6 -0
  303. package/ts/array/reverse.ts +5 -0
  304. package/ts/array/union_of_props.ts +1 -1
  305. package/ts/assertion/assert_type.ts +4 -1
  306. package/ts/assertion/readme.md +4 -3
  307. package/ts/functional/compose.ts +2 -1
  308. package/ts/functional/context.ts +1 -1
  309. package/ts/index.ts +22 -3
  310. package/ts/math/numeric_struct.ts +9 -9
  311. package/ts/mix_types/any_or_never_type.ts +1 -1
  312. package/ts/mix_types/readme.md +7 -1
  313. package/ts/never/never_type.ts +13 -0
  314. package/ts/nodejs/isNodeError.ts +13 -13
  315. package/ts/nominal/brand.ts +1 -1
  316. package/ts/nominal/flavor.ts +1 -1
  317. package/ts/object/index.ts +0 -1
  318. package/ts/testing/readme.md +30 -0
  319. package/ts/testing/test_type.ts +279 -234
  320. package/ts/tuple/common_prop_keys.ts +41 -0
  321. package/ts/tuple/create_tuple.ts +9 -9
  322. package/ts/tuple/drop.ts +125 -0
  323. package/ts/tuple/readme.md +263 -9
  324. package/ts/{array → tuple}/tail.ts +1 -1
  325. package/ts/tuple/tuple_plus.common_prop_keys.ts +47 -0
  326. package/ts/tuple/tuple_plus.drop_match.ts +20 -0
  327. package/ts/tuple/tuple_plus.filter.ts +29 -0
  328. package/ts/tuple/tuple_plus.find.ts +88 -0
  329. package/ts/tuple/tuple_plus.pad_start.ts +37 -21
  330. package/ts/tuple/tuple_plus.ts +5 -1
  331. package/ts/tuple/tuple_type.ts +67 -25
  332. package/ts/union/readme.md +81 -0
  333. package/ts/union/union.ts +37 -0
  334. package/ts/unknown/unknown_type.ts +13 -0
  335. package/ts/utils/options.ts +10 -0
  336. package/cjs/array/array.concat.d.ts.map +0 -1
  337. package/cjs/array/array.concat.js.map +0 -1
  338. package/cjs/array/array.find.d.ts +0 -21
  339. package/cjs/array/array.find.d.ts.map +0 -1
  340. package/cjs/array/array.find.js.map +0 -1
  341. package/cjs/array/common_prop_keys.d.ts +0 -11
  342. package/cjs/array/common_prop_keys.d.ts.map +0 -1
  343. package/cjs/array/common_prop_keys.js.map +0 -1
  344. package/cjs/array/drop.d.ts +0 -19
  345. package/cjs/array/drop.d.ts.map +0 -1
  346. package/cjs/array/drop.js.map +0 -1
  347. package/cjs/array/index.d.ts +0 -17
  348. package/cjs/array/index.d.ts.map +0 -1
  349. package/cjs/array/index.js +0 -33
  350. package/cjs/array/index.js.map +0 -1
  351. package/esm/array/array.concat.d.ts.map +0 -1
  352. package/esm/array/array.concat.js +0 -2
  353. package/esm/array/array.concat.js.map +0 -1
  354. package/esm/array/array.find.d.ts +0 -21
  355. package/esm/array/array.find.d.ts.map +0 -1
  356. package/esm/array/array.find.js +0 -2
  357. package/esm/array/array.find.js.map +0 -1
  358. package/esm/array/common_prop_keys.d.ts +0 -11
  359. package/esm/array/common_prop_keys.d.ts.map +0 -1
  360. package/esm/array/common_prop_keys.js.map +0 -1
  361. package/esm/array/drop.d.ts +0 -19
  362. package/esm/array/drop.d.ts.map +0 -1
  363. package/esm/array/drop.js +0 -7
  364. package/esm/array/drop.js.map +0 -1
  365. package/esm/array/index.d.ts +0 -17
  366. package/esm/array/index.d.ts.map +0 -1
  367. package/esm/array/index.js +0 -17
  368. package/esm/array/index.js.map +0 -1
  369. package/ts/array/array.find.ts +0 -32
  370. package/ts/array/common_prop_keys.ts +0 -18
  371. package/ts/array/drop.ts +0 -71
  372. package/ts/array/index.ts +0 -16
  373. /package/cjs/{array → tuple}/common_prop_keys.js +0 -0
  374. /package/cjs/{array → tuple}/tail.js +0 -0
  375. /package/esm/{array → tuple}/common_prop_keys.js +0 -0
  376. /package/esm/{array → tuple}/tail.js +0 -0
package/README.md CHANGED
@@ -8,44 +8,48 @@
8
8
 
9
9
  [![Visual Studio Code][vscode_image]][vscode_url]
10
10
 
11
- More than 200 type utilities for [TypeScript].
11
+ More than 200 type utilities for [TypeScript] for applications, library, and type-level programming.
12
12
 
13
13
  ## Table of Contents
14
14
 
15
- 1. [Assertion Function](#assertion-function)
15
+ 1. [What's in the package?](#whats-in-the-package)
16
+ 1. [Update organization](#update-organization)
17
+ 2. [Update documentation](#update-documentation)
18
+ 2. [Assertion Function](#assertion-function)
16
19
  1. [assertType](#asserttype)
17
- 2. [Type Guard](#type-guard)
18
- 3. [Type Utilities](#type-utilities)
19
- 4. [Type Specific Utilities](#type-specific-utilities)
20
+ 3. [Type Guard](#type-guard)
21
+ 4. [Type Utilities](#type-utilities)
22
+ 5. [Type Specific Utilities](#type-specific-utilities)
20
23
  1. [any](#any)
21
24
  2. [Array](#array)
22
- 3. [bigint](#bigint)
23
- 4. [boolean](#boolean)
24
- 5. [function](#function)
25
- 6. [never](#never)
26
- 7. [null](#null)
27
- 8. [number](#number)
28
- 9. [numeric](#numeric)
29
- 10. [object](#object)
30
- 11. [Promise](#promise)
31
- 12. [string](#string)
32
- 13. [symbol](#symbol)
33
- 14. [tuple](#tuple)
34
- 15. [undefined](#undefined)
35
- 16. [unknown](#unknown)
36
- 17. [void](#void)
37
- 5. [Constant Types](#constant-types)
38
- 6. [JSON Support](#json-support)
39
- 7. [Type manipulation](#type-manipulation)
40
- 8. [Type Predicates](#type-predicates)
25
+ 3. [union](#union)
26
+ 4. [bigint](#bigint)
27
+ 5. [boolean](#boolean)
28
+ 6. [function](#function)
29
+ 7. [never](#never)
30
+ 8. [null](#null)
31
+ 9. [number](#number)
32
+ 10. [numeric](#numeric)
33
+ 11. [object](#object)
34
+ 12. [Promise](#promise)
35
+ 13. [string](#string)
36
+ 14. [symbol](#symbol)
37
+ 15. [tuple](#tuple)
38
+ 16. [undefined](#undefined)
39
+ 17. [unknown](#unknown)
40
+ 18. [void](#void)
41
+ 6. [Constant Types](#constant-types)
42
+ 7. [JSON Support](#json-support)
43
+ 8. [Type manipulation](#type-manipulation)
44
+ 9. [Type Predicates](#type-predicates)
41
45
  1. [Logical](#logical)
42
- 9. [Math](#math)
43
- 10. [Utility Functions](#utility-functions)
44
- 11. [Nominal Types](#nominal-types)
45
- 12. [Functional Types](#functional-types)
46
- 13. [Attribution](#attribution)
47
- 14. [Useful Tips](#useful-tips)
48
- 15. [Similar projects](#similar-projects)
46
+ 10. [Math](#math)
47
+ 11. [Utility Functions](#utility-functions)
48
+ 12. [Nominal Types](#nominal-types)
49
+ 13. [Functional Types](#functional-types)
50
+ 14. [Attribution](#attribution)
51
+ 15. [Useful Tips](#useful-tips)
52
+ 16. [Similar projects](#similar-projects)
49
53
 
50
54
  ## Installation
51
55
 
@@ -57,6 +61,53 @@ yarn add type-plus
57
61
  pnpm add type-plus
58
62
  ```
59
63
 
64
+ ## What's in the package?
65
+
66
+ With over 200 types in [type-plus],
67
+ it can become difficult to find the types you need.
68
+
69
+ Also, some of the types need to be updated as TypeScript continue to evolve.
70
+
71
+ Currently, we are updating [type-plus] with the following objective:
72
+
73
+ - Update organization
74
+ - Update documentation
75
+ - Clean up and deprecate types
76
+ - Upgrade TypeScript from 5.0.4 to 5.1 (potential breaking changes)
77
+
78
+ ### Update organization
79
+
80
+ Top-level exports of [type-plus] will contain types and functions that do not expect the input to be a specific type. For example,
81
+
82
+ - `assertType()`, `isType()`, and `testType()`
83
+ - Type filters and predicates such as `AnyType` or `IsArray`
84
+
85
+ It can also have types and functions for specific types if it is a common convention,
86
+ or the is no ambiguity, or for backwards compatibility purpose.
87
+
88
+ Other type specific utilities will be added under their respective `*Plus` namespaces such as `ArrayPlus.At` or `NumberPlus.Positive`.
89
+
90
+ ### Update documentation
91
+
92
+ Each type and utility function in [type-plus] will be updated to include examples and tags to indicate its category and behavior.
93
+
94
+ Each tag has an associated icon:
95
+
96
+ - 👽 *alias*: Alias of another type
97
+ - 🚦 *assertion*: assertion function
98
+ - 🔢 *customizable*: the behavior of the type is customizable.
99
+ - 💀 *deprecated*: deprecated and will be removed soon
100
+ - 🌪️ *filter*: a.k.a. *parse* These types perform some kind of test. If the input passes the test, the input is returned. Otherwise, it returns `never`
101
+ - 🛡️ *guard*: type guard function
102
+ - 💥 *immediate*: the effect of the type can be observed immediately during development
103
+ - ㊙️ *internal*: the type is internal and should not be used directly
104
+ - 🏃 *runtime*: the function has runtime effect
105
+ - 🩳 *shortcut*: Shortcut or convenient types
106
+ - 🧪 *testing*: the type or function are designed for test
107
+ - ⚗️ *transform*: these types transforms the input to another category
108
+ - 🦴 *utilities*: provide various functionalities
109
+ - 🎭 *validate*: a.k.a. *predicate* or *logical*. These types perform some kind of test. If the input passes the test, it returns `true` or `false`
110
+
60
111
  ## Assertion Function
61
112
 
62
113
  [Assertion Functions][assertion_functions] are special functions that asserts certain conditions of your program.
@@ -327,150 +378,52 @@ You can learn more in their respective sections:
327
378
  - [void](./ts/void/readme.md)
328
379
  - [mix types](./ts/mix-types/readme.md)
329
380
 
330
- ### any
331
-
332
- > [`AnyType<T>`](./ts/any/readme.md#type-checking)
333
-
334
- ↪️ `parse`: `T === any`.
335
-
336
- > [`IsAny<T>`](./ts/any/readme.md#type-checking)
337
-
338
- ⭕ `predicate`: `T === any`.
339
-
340
- > [`NotAnyType<T>`](./ts/any/readme.md#type-checking)
341
-
342
- ↪️ `parse`: `T !== any`.
343
-
344
- > [`IsNotAny<T>`](./ts/any/readme.md#type-checking)
345
-
346
- `predicate`: `T !== any`.
347
-
348
- > [`IsAnyOrNever<T>`](./ts/any/readme.md#type-utilities)
349
-
350
- `predicate`: `T === any || T === never`.
351
-
352
- ### Array
353
-
354
- > [`ArrayType<T>`](./ts/array/readme.md#type-checking)
355
-
356
- ↪️ `parse`: is the type `T` exactly an array and not a tuple.
357
-
358
- > [`IsArray<T>`](./ts/array/readme.md#type-checking)
359
-
360
- `predicate`: is the type `T` exactly an array and not a tuple.
361
-
362
- > [`NotArrayType<T>`](./ts/array/readme.md#type-checking)
363
-
364
- ↪️ `parse`: is the type `T` not an array or tuple.
365
-
366
- > [`IsNotArray<T>`](./ts/array/readme.md#type-checking)
367
-
368
- `predicate`: is the type `T` exactly an array and not a tuple.
369
-
370
- > [`At<A, N, Fail = never>`](ts/array_plus/array.ts#L19)
371
-
372
- 🔨 `utilities`: gets the element type at index `N` in the array `A`.
373
-
374
- > `CommonPropKeys<A>`
375
-
376
- 🔨 `utilities`: gets common keys inside the records in the array `A` (deprecate `CommonKeys`).
377
-
378
- > [`Concat<A, B>`](ts/array_plus/array.ts#L38)
379
-
380
- 🔨 `utilities`: `[...A, ...B]`.
381
-
382
- > `CreateTuple<L, T>`
383
-
384
- 🔨 `utilities`: creates `tuple<T>` with `L` number of elements.
385
-
386
- > `drop(array, value)`
387
-
388
- 🔨 `utilities`: drop a particular value from an array.
389
-
390
- > `DropFirst<A>`
391
-
392
- 🔨 `utilities`: drops the first value type of `A`.
393
-
394
- > `DropLast<A>`
395
-
396
- 🔨 `utilities`: drops the last value type of `A`.
397
-
398
- > `DropMatch<A, Criteria>`
399
-
400
- 🔨 `utilities`: drops entries matching `Criteria` in array or tuple `A`.
401
-
402
- > `DropUndefined<A>`
403
-
404
- 🔨 `utilities`: drop undefined entries from array of tuple `A`.
405
-
406
- > `Filter<A, Criteria>`
407
-
408
- 💀🔨 `deprecated`,`utilities`: filter the array or tuple `A`, keeping entries satisfying `Criteria`. **Deprecated. Renaming to `KeepMatch`**
409
-
410
- > `FindFirst<A, Criteria>`
411
-
412
- 🔨 `utilities`: gets the first type satisfying `Criteria`.
413
-
414
- > `FindLast<A, Criteria>`
415
-
416
- 🔨 `utilities`: gets the last type satisfying `Criteria`.
417
-
418
- > `Head<A>`
419
-
420
- 🔨 `utilities`: gets the first entry in the array.
421
-
422
- > `IntersectOfProps<A, K>`
423
-
424
- 🔨 `utilities`: gets the intersect of `A[K]` types (deprecate `MapToProp`)
425
-
426
- > `KeepMatch<A, Criteria>`
427
-
428
- 🔨 `utilities`: keeps entries satisfying `Criteria` in array or tuple `A`.
429
-
430
- > `Last<A>`
431
-
432
- 🔨 `utilities`: gets the last type of array or tuple.
433
-
434
- > `literalArray(...entries)`
435
-
436
- 🔨 `utilities`: return an array whose items are restricted to the provided literals.
437
-
438
- > `PadLeft<A, Total, PadWith>`
439
-
440
- 🔨 `utilities`: pads `A` with `PadWith` if the length of `A` is less than `L`.
441
-
442
- > `reduceWhile()`
443
-
444
- 🔨 `utilities`: `reduce()` with predicate for early termination. \
445
- A simple version of the same function in the `ramda` package.
446
-
447
- > `Reverse<A>`
448
-
449
- 🔨 `utilities`: reverses the order of `A`.
450
-
451
- > `Some<A, Criteria>`
452
-
453
- 🔨 `utilities`: true if some elements in `A` matches `Criteria`.
454
-
455
- > `Tail<A>`
456
-
457
- 🔨 `utilities`: Gets the types of a tuple except the first entry.
458
-
459
- > `UnionOfProps<A, K>`
460
-
461
- 🔨 `utilities`: gets the union of `A[K]` types (deprecate `PropUnion`).
462
-
463
- > `UnionOfValues<A>`
464
-
465
- 🔨 `utilities`: gets the union of value types in `A` (deprecate `ArrayValue`).
466
-
467
- > [`ArrayPlus.IndexAt<A, N, Fail = never>`](ts/array_plus/array_plus.ts#L23)
468
-
469
- 🔨 `utilities`: gets the normalized index for `A`.
470
-
471
- > [`ArrayPlus.IsIndexOutOfBound<A, N, Then = true, Else = false>`](ts/array_plus/array_plus.ts#L62)
472
-
473
- ⭕ `predicate`: is `N` an out of bound index of `A`. Supports negative numbers.
381
+ ### [any](./ts/any/readme.md)
382
+
383
+ - [`AnyType`](./ts/any/readme.md#anytype)
384
+ - [`IsAny`](./ts/any/readme.md#isany)
385
+ - [`NotAnyType`](./ts/any/readme.md#notanytype)
386
+ - [`IsNotAny`](./ts/any/readme.md#isnotany)
387
+ - [`AnyOrNeverType`](./ts/mix_types/readme.md#anyornevertype)
388
+ - [`IsAnyOrNever`](./ts/mix_types/readme.md#isanyornever)
389
+
390
+ ### [Array](./ts/array/readme.md)
391
+
392
+ - 🌪️[`ArrayType`](./ts/array/readme.md#arraytype): Filter `T` to ensure it is an array, excluding tuple.
393
+ - 🎭[`IsArray`](./ts/array/readme.md#isarray): Validate that `T` is an array, excluding tuple.
394
+ - 🌪️[`NotArrayType`](./ts/array/readme.md#notarraytype): Filter `T` to ensure it is not an array, excluding tuple.
395
+ - 🎭[`IsNotArrayType`](./ts/array/readme.md#isnotarraytype): Validate that `T` is not an array, excluding tuple.
396
+ - 🦴[`At`](./ts/array/readme.md#at): Gets the type of the array or tuple at positive or negative index `N`.
397
+ - 🦴💀[`Concat`](./ts/array/readme.md#concat): Concats two arrays or tuples.
398
+ - 🦴🔢[`FindFirst`](./ts/array/readme.md#findfirst): Find the first type in the array or tuple `A` that matches `Criteria`.
399
+ - [`FindLast`](./ts/array/readme.md#findlast)
400
+ - [`Some`](./ts/array/readme.md#some)
401
+ - ⚗️[`Filter`](./ts/array/readme.md#filter): Filter the array or tuple `A`, keeping entries satisfying `Criteria`.
402
+ - ⚗️👽[`KeepMatch`](./ts/array/readme.md#keepmatch): Keeps entries satisfying `Criteria` in array or tuple `A`.
403
+ - 🦴🔢[`Head`](./ts/array/readme.md#head): Gets the first entry in the tuple or the type of array `T`.
404
+ - [`IntersectOfProps`](./ts/array/readme.md#intersectofprops)
405
+ - [`MapToProp`](./ts/array/readme.md#maptoprop)
406
+ - 🦴🔢[`Last`](./ts/array/readme.md#last): Gets the last entry in the tuple or the type of array `T`.
407
+ - [`literalArray`](./ts/array/readme.md#literalarray)
408
+ - [`PadStart`](./ts/array/readme.md#padstart)
409
+ - [`reduceWhile`](./ts/array/readme.md#reducewhile)
410
+ - [`Reverse`](./ts/array/readme.md#reverse)
411
+ - [`PropUnion`](./ts/array/readme.md#propunion)
412
+ - [`UnionOfProps`](./ts/array/readme.md#unionofprops)
413
+ - [`UnionOfValues`](./ts/array/readme.md#unionofvalues)
414
+ - [`ArrayPlus.At`](./ts/array/readme.md#arrayplusat)
415
+ - [`ArrayPlus.Concat`](./ts/array/readme.md#arrayplusconcat)
416
+ - [`ArrayPlus.Entries`](./ts/array/readme.md#arrayplusentries)
417
+ - 🦴🔢[`ArrayPlus.Find`](./ts/array/readme.md#arrayplusfind): Finds the type in array `A` that matches `Criteria`.
418
+ - [`ArrayPlus.FindLast`](./ts/array/readme.md#arrayplusfindlast)
419
+ - [`ArrayPlus.Reverse`](./ts/array/readme.md#arrayplusreverse)
420
+ - [`ArrayPlus.SplitAt`](./ts/array/readme.md#arrayplussplitat)
421
+ - [`ArrayPlus.Some`](./ts/array/readme.md#arrayplussome)
422
+
423
+ ### [union](./ts/union/readme.md)
424
+
425
+ - [`IsUnion`](./ts/union//readme.md#isunion)
426
+ - [`UnionType`](./ts/union/readme.md#uniontype)
474
427
 
475
428
  ### bigint
476
429
 
@@ -812,21 +765,30 @@ You can learn more in their respective sections:
812
765
 
813
766
  ### tuple
814
767
 
815
- > [`TupleType<T>`](ts/tuple/readme.md#type-checking)
768
+ - 🌪️ [`TupleType`](./ts/tuple/readme.md#tupletype): Filter `T` to ensure it is a tuple, excluding array.
769
+ - 🎭 [`IsTuple`](./ts/tuple/readme.md#istuple): Validate that `T` is a tuple, excluding array.
770
+ - 🌪️ [`NotTupleType`](./ts/tuple/readme.md#nottupletype): Filter `T` to ensure it is not an tuple, excluding array.
771
+ - 🎭 [`IsNotTuple`](./ts/tuple/readme.md#isnottupletype): Validate that `T` is not an tuple, excluding array.
772
+ - ⚗️🔢[`CommonPropKeys`](./ts/tuple/readme.md#commonpropkeys): Gets the common property keys of the elements in tuple `T`.
773
+ - ⚗️💀`CommonKeys`: Deprecated. Please use `CommonPropKeys` instead.
774
+ - ⚗️🔢[`DropFirst`](./ts/tuple/readme.md#dropfirst): Drops the first entry in the tuple`T`.
775
+ - ⚗️🔢[`DropLast`](./ts/tuple/readme.md#droplast): Drops the last entry in the tuple`T`.
816
776
 
817
- ↪️ `parse`: is a tuple.
777
+ > `CreateTuple<L, T>`
778
+
779
+ 🔨 `utilities`: creates `tuple<T>` with `L` number of elements.
818
780
 
819
- > [`IsTuple<T>`](ts/tuple/readme.md#type-checking)
781
+ > `drop(array, value)`
820
782
 
821
- `predicate`: is a tuple.
783
+ 🔨 `utilities`: drop a particular value from an array.
822
784
 
823
- > [`NotTupleType<T>`](ts/tuple/readme.md#type-checking)
785
+ > `DropMatch<A, Criteria>`
824
786
 
825
- ↪️ `parse`: is not a tuple.
787
+ 🔨 `utilities`: drops entries matching `Criteria` in array or tuple `A`.
826
788
 
827
- > [`IsNotTuple<T>`](ts/tuple/readme.md#type-checking)
789
+ > `DropUndefined<A>`
828
790
 
829
- `predicate`: is not a tuple.
791
+ 🔨 `utilities`: drop undefined entries from array of tuple `A`.
830
792
 
831
793
  ### undefined
832
794
 
@@ -1381,6 +1343,7 @@ Whenever possible, I add attribution to the person who created those **codes** i
1381
1343
  [ts-expect]: https://github.com/TypeStrong/ts-expect
1382
1344
  [ts-toolbelt]: https://github.com/millsp/ts-toolbelt
1383
1345
  [type-fest]: https://github.com/sindresorhus/type-fest
1346
+ [type-plus]: https://github.com/unional/type-plus
1384
1347
  [type-zoo]: https://github.com/pelotom/type-zoo
1385
1348
  [typelevel-ts]: https://github.com/gcanti/typelevel-ts
1386
1349
  [typepark]: https://github.com/kgtkr/typepark
@@ -1,7 +1,7 @@
1
1
  /**
2
- * Parse `T` to ensure it is exactly `any`.
2
+ * 🌪️ *filter*
3
3
  *
4
- * 🐾 *parse*
4
+ * Filter `T` to ensure it is exactly `any`.
5
5
  *
6
6
  * @example
7
7
  * ```ts
@@ -14,10 +14,10 @@
14
14
  */
15
15
  export type AnyType<T, Then = T, Else = never> = 0 extends 1 & T ? Then : Else;
16
16
  /**
17
- * Validate if `T` is exactly `any`.
18
- *
19
17
  * 🎭 *validate*
20
18
  *
19
+ * Validate if `T` is exactly `any`.
20
+ *
21
21
  * @example
22
22
  * ```ts
23
23
  * type R = IsAny<any> // true
@@ -29,9 +29,9 @@ export type AnyType<T, Then = T, Else = never> = 0 extends 1 & T ? Then : Else;
29
29
  */
30
30
  export type IsAny<T, Then = true, Else = false> = AnyType<T, Then, Else>;
31
31
  /**
32
- * Parse `T` to ensure it is not exactly `any`.
32
+ * 🌪️ *filter*
33
33
  *
34
- * 🐾 *parse*
34
+ * Filter `T` to ensure it is not exactly `any`.
35
35
  *
36
36
  * @example
37
37
  * ```ts
@@ -44,10 +44,10 @@ export type IsAny<T, Then = true, Else = false> = AnyType<T, Then, Else>;
44
44
  */
45
45
  export type NotAnyType<T, Then = T, Else = never> = AnyType<T, Else, Then>;
46
46
  /**
47
- * Validate if `T` is not exactly `any`.
48
- *
49
47
  * 🎭 *validate*
50
48
  *
49
+ * Validate if `T` is not exactly `any`.
50
+ *
51
51
  * @example
52
52
  * ```ts
53
53
  * import type { IsNotAny } from 'type-plus'
@@ -1 +1 @@
1
- {"version":3,"file":"any_type.d.ts","sourceRoot":"","sources":["../../ts/any/any_type.ts"],"names":[],"mappings":"AACA;;;;;;;;;;;;;GAaG;AACH,MAAM,MAAM,OAAO,CAAC,CAAC,EAAE,IAAI,GAAG,CAAC,EAAE,IAAI,GAAG,KAAK,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,GAAG,IAAI,GAAG,IAAI,CAAA;AAE9E;;;;;;;;;;;;;GAaG;AACH,MAAM,MAAM,KAAK,CAAC,CAAC,EAAE,IAAI,GAAG,IAAI,EAAE,IAAI,GAAG,KAAK,IAAI,OAAO,CAAC,CAAC,EAAE,IAAI,EAAE,IAAI,CAAC,CAAA;AAExE;;;;;;;;;;;;;GAaG;AACH,MAAM,MAAM,UAAU,CAAC,CAAC,EAAE,IAAI,GAAG,CAAC,EAAE,IAAI,GAAG,KAAK,IAAI,OAAO,CAAC,CAAC,EAAE,IAAI,EAAE,IAAI,CAAC,CAAA;AAE1E;;;;;;;;;;;;;;;GAeG;AACH,MAAM,MAAM,QAAQ,CAAC,CAAC,EAAE,IAAI,GAAG,IAAI,EAAE,IAAI,GAAG,KAAK,IAAI,OAAO,CAAC,CAAC,EAAE,IAAI,EAAE,IAAI,CAAC,CAAA"}
1
+ {"version":3,"file":"any_type.d.ts","sourceRoot":"","sources":["../../ts/any/any_type.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AACH,MAAM,MAAM,OAAO,CAAC,CAAC,EAAE,IAAI,GAAG,CAAC,EAAE,IAAI,GAAG,KAAK,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,GAAG,IAAI,GAAG,IAAI,CAAA;AAE9E;;;;;;;;;;;;;GAaG;AACH,MAAM,MAAM,KAAK,CAAC,CAAC,EAAE,IAAI,GAAG,IAAI,EAAE,IAAI,GAAG,KAAK,IAAI,OAAO,CAAC,CAAC,EAAE,IAAI,EAAE,IAAI,CAAC,CAAA;AAExE;;;;;;;;;;;;;GAaG;AACH,MAAM,MAAM,UAAU,CAAC,CAAC,EAAE,IAAI,GAAG,CAAC,EAAE,IAAI,GAAG,KAAK,IAAI,OAAO,CAAC,CAAC,EAAE,IAAI,EAAE,IAAI,CAAC,CAAA;AAE1E;;;;;;;;;;;;;;;GAeG;AACH,MAAM,MAAM,QAAQ,CAAC,CAAC,EAAE,IAAI,GAAG,IAAI,EAAE,IAAI,GAAG,KAAK,IAAI,OAAO,CAAC,CAAC,EAAE,IAAI,EAAE,IAAI,CAAC,CAAA"}
@@ -2,7 +2,9 @@ import type { IsStrictNumber } from '../number/strict_number_type.js';
2
2
  import type { TupleType } from '../tuple/tuple_type.js';
3
3
  import type { IndexAt } from './array_index.js';
4
4
  /**
5
- * Gets the type of the array or tuple at index `N`.
5
+ * 🦴 *utilities*
6
+ *
7
+ * Gets the type of the array or tuple at positive or negative index `N`.
6
8
  *
7
9
  * Like `Array.at()`, this type supports negative numbers.
8
10
  *
@@ -1 +1 @@
1
- {"version":3,"file":"array.at.d.ts","sourceRoot":"","sources":["../../ts/array/array.at.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAA;AACrE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAA;AACvD,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAA;AAE/C;;;;;;;;;;;;GAYG;AACH,MAAM,MAAM,EAAE,CAAC,CAAC,SAAS,OAAO,EAAE,EAAE,CAAC,SAAS,MAAM,EAAE,IAAI,GAAG,KAAK,IAAI,OAAO,CAC5E,CAAC,EACD,CAAC,EACD,IAAI,EACJ,IAAI,EACJ,IAAI,CACJ,SAAS,MAAM,CAAC,GACd,CAAC,SAAS,MAAM,GACf,SAAS,CAAC,CAAC,EAAE,cAAc,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,GAAG,SAAS,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,GAAG,SAAS,CAAC,GACzE,IAAI,GACL,KAAK,CAAA"}
1
+ {"version":3,"file":"array.at.d.ts","sourceRoot":"","sources":["../../ts/array/array.at.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAA;AACrE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAA;AACvD,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAA;AAE/C;;;;;;;;;;;;;;GAcG;AACH,MAAM,MAAM,EAAE,CAAC,CAAC,SAAS,OAAO,EAAE,EAAE,CAAC,SAAS,MAAM,EAAE,IAAI,GAAG,KAAK,IAAI,OAAO,CAC5E,CAAC,EACD,CAAC,EACD,IAAI,EACJ,IAAI,EACJ,IAAI,CACJ,SAAS,MAAM,CAAC,GACd,CAAC,SAAS,MAAM,GACf,SAAS,CAAC,CAAC,EAAE,cAAc,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,GAAG,SAAS,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,GAAG,SAAS,CAAC,GACzE,IAAI,GACL,KAAK,CAAA"}
@@ -11,7 +11,8 @@ import type { IsTuple } from '../tuple/tuple_type.js';
11
11
  * ArrayPlus.Entries<[1, 2, 3]> // [[0, 1], [1, 2], [2, 3]]
12
12
  * ```
13
13
  */
14
- export type Entries<A extends unknown[]> = IsTuple<A, Device<A, []>, A extends Array<infer T> ? Array<[number, T]> : never>;
15
- type Device<A extends unknown[], R extends unknown[]> = A['length'] extends 0 ? R : A extends [...infer F, infer N] ? Device<F, [[F['length'], N], ...R]> : never;
16
- export {};
14
+ export type Entries<A extends unknown[]> = IsTuple<A, Entries.Device<A, []>, A extends Array<infer T> ? Array<[number, T]> : never>;
15
+ export declare namespace Entries {
16
+ type Device<A extends unknown[], R extends unknown[]> = A['length'] extends 0 ? R : A extends [...infer F, infer N] ? Device<F, [[F['length'], N], ...R]> : never;
17
+ }
17
18
  //# sourceMappingURL=array.entries.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"array.entries.d.ts","sourceRoot":"","sources":["../../ts/array/array.entries.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,wBAAwB,CAAA;AACrD;;;;;;;;;;;GAWG;AACH,MAAM,MAAM,OAAO,CAAC,CAAC,SAAS,OAAO,EAAE,IAAI,OAAO,CACjD,CAAC,EACD,MAAM,CAAC,CAAC,EAAE,EAAE,CAAC,EACb,CAAC,SAAS,KAAK,CAAC,MAAM,CAAC,CAAC,GAAG,KAAK,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,CAAC,GAAG,KAAK,CACrD,CAAA;AAED,KAAK,MAAM,CAAC,CAAC,SAAS,OAAO,EAAE,EAAE,CAAC,SAAS,OAAO,EAAE,IAAI,CAAC,CAAC,QAAQ,CAAC,SAAS,CAAC,GAC1E,CAAC,GACD,CAAC,SAAS,CAAC,GAAG,MAAM,CAAC,EAAE,MAAM,CAAC,CAAC,GAC/B,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,EAAE,GAAG,CAAC,CAAC,CAAC,GACnC,KAAK,CAAA"}
1
+ {"version":3,"file":"array.entries.d.ts","sourceRoot":"","sources":["../../ts/array/array.entries.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,wBAAwB,CAAA;AACrD;;;;;;;;;;;GAWG;AACH,MAAM,MAAM,OAAO,CAAC,CAAC,SAAS,OAAO,EAAE,IAAI,OAAO,CACjD,CAAC,EACD,OAAO,CAAC,MAAM,CAAC,CAAC,EAAE,EAAE,CAAC,EACrB,CAAC,SAAS,KAAK,CAAC,MAAM,CAAC,CAAC,GAAG,KAAK,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,CAAC,GAAG,KAAK,CACrD,CAAA;AAED,yBAAiB,OAAO,CAAC;IACxB,KAAY,MAAM,CAAC,CAAC,SAAS,OAAO,EAAE,EAAE,CAAC,SAAS,OAAO,EAAE,IAAI,CAAC,CAAC,QAAQ,CAAC,SAAS,CAAC,GAClF,CAAC,GACD,CAAC,SAAS,CAAC,GAAG,MAAM,CAAC,EAAE,MAAM,CAAC,CAAC,GAC/B,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,EAAE,GAAG,CAAC,CAAC,CAAC,GACnC,KAAK,CAAA;CACP"}
@@ -1,6 +1,8 @@
1
1
  import type { TupleType } from '../tuple/tuple_type.js';
2
2
  /**
3
- * Returns the last type in the array or tuple that matches the `Criteria`.
3
+ * 🦴 *utilities*
4
+ *
5
+ * Gets the last type in the array or tuple that matches the `Criteria`.
4
6
  *
5
7
  * If the `Criteria` is not met, it will return `never'.
6
8
  *
@@ -1 +1 @@
1
- {"version":3,"file":"array.find_last.d.ts","sourceRoot":"","sources":["../../ts/array/array.find_last.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAA;AAEvD;;;;;;;;;;;;;GAaG;AACH,MAAM,MAAM,QAAQ,CAAC,CAAC,SAAS,KAAK,CAAC,GAAG,CAAC,EAAE,QAAQ,IAAI,SAAS,CAC/D,CAAC,EACD,CAAC,CAAC,QAAQ,CAAC,SAAS,CAAC,GAClB,KAAK,GACL,CAAC,SAAS,CAAC,GAAG,MAAM,KAAK,EAAE,MAAM,IAAI,CAAC,GACtC,IAAI,SAAS,QAAQ,GACpB,IAAI,GACJ,QAAQ,CAAC,KAAK,EAAE,QAAQ,CAAC,GAC1B,KAAK,EACR,CAAC,SAAS,KAAK,CAAC,MAAM,CAAC,CAAC,GAAG,CAAC,CAAC,SAAS,QAAQ,GAAG,CAAC,GAAG,SAAS,GAAG,KAAK,CAAC,GAAG,KAAK,CAC/E,CAAA"}
1
+ {"version":3,"file":"array.find_last.d.ts","sourceRoot":"","sources":["../../ts/array/array.find_last.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAA;AAEvD;;;;;;;;;;;;;;;GAeG;AACH,MAAM,MAAM,QAAQ,CAAC,CAAC,SAAS,KAAK,CAAC,GAAG,CAAC,EAAE,QAAQ,IAAI,SAAS,CAC/D,CAAC,EACD,CAAC,CAAC,QAAQ,CAAC,SAAS,CAAC,GAClB,KAAK,GACL,CAAC,SAAS,CAAC,GAAG,MAAM,KAAK,EAAE,MAAM,IAAI,CAAC,GACtC,IAAI,SAAS,QAAQ,GACpB,IAAI,GACJ,QAAQ,CAAC,KAAK,EAAE,QAAQ,CAAC,GAC1B,KAAK,EACR,CAAC,SAAS,KAAK,CAAC,MAAM,CAAC,CAAC,GAAG,CAAC,CAAC,SAAS,QAAQ,GAAG,CAAC,GAAG,SAAS,GAAG,KAAK,CAAC,GAAG,KAAK,CAC/E,CAAA"}
@@ -1,6 +1,6 @@
1
1
  import type { IsEqual } from '../equal/equal.js';
2
2
  import type { CanAssign } from '../index.js';
3
- import type { Tail } from './tail.js';
3
+ import type { Tail } from '../tuple/tail.js';
4
4
  import type { UnionOfValues } from './union_of_values.js';
5
5
  /**
6
6
  * Determines whether the array type `A` contains any elements that satisfies the specified `Criteria` type.
@@ -1 +1 @@
1
- {"version":3,"file":"array.some.d.ts","sourceRoot":"","sources":["../../ts/array/array.some.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAA;AAChD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,aAAa,CAAA;AAC5C,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,WAAW,CAAA;AACrC,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAA;AAEzD;;;;;;;;;;;;;;;;;;GAkBG;AACH,MAAM,MAAM,IAAI,CACf,CAAC,SAAS,GAAG,EAAE,EACf,QAAQ,EACR,IAAI,SAAS,QAAQ,GAAG,OAAO,GAAG,OAAO,EACzC,IAAI,GAAG,IAAI,EACX,IAAI,GAAG,KAAK,IACT,IAAI,SAAS,QAAQ,GAAG,IAAI,CAAC,MAAM,CAAC,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,CAAC,CAAA;AAEtG,yBAAiB,IAAI,CAAC;IACrB,KAAY,MAAM,CAAC,CAAC,SAAS,OAAO,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,IAAI,MAAM,SAAS,CAAC,CAAC,QAAQ,CAAC,GACvF,WAAW,CAAC,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,CAAC,GACpC,WAAW,CAAC,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,CAAC,CAAA;IAEvC,KAAY,WAAW,CAAC,CAAC,SAAS,OAAO,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,IAAI,OAAO,CAC3E,aAAa,CAAC,CAAC,CAAC,EAChB,QAAQ,EACR,IAAI,EACJ,IAAI,CACJ,CAAA;IAED,KAAY,WAAW,CAAC,CAAC,SAAS,OAAO,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,IAAI,CAAC,CAAC,QAAQ,CAAC,SAAS,CAAC,GACvF,IAAI,GACJ,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,QAAQ,CAAC,SAAS,IAAI,GACpC,IAAI,GACJ,WAAW,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,CAAC,CAAA;IAE7C,KAAY,KAAK,CAAC,CAAC,SAAS,OAAO,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,IAAI,MAAM,SAAS,CAAC,CAAC,QAAQ,CAAC,GACtF,UAAU,CAAC,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,CAAC,GACnC,UAAU,CAAC,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,CAAC,CAAA;IAEtC,KAAY,UAAU,CAAC,CAAC,SAAS,OAAO,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,IAAI,SAAS,CAC5E,aAAa,CAAC,CAAC,CAAC,EAChB,QAAQ,EACR,IAAI,EACJ,IAAI,CACJ,CAAA;IAED,KAAY,UAAU,CAAC,CAAC,SAAS,OAAO,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,IAAI,CAAC,CAAC,QAAQ,CAAC,SAAS,CAAC,GACtF,IAAI,GACJ,CAAC,CAAC,CAAC,CAAC,SAAS,QAAQ,GACrB,IAAI,GACJ,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,CAAC,CAAA;CAC5C"}
1
+ {"version":3,"file":"array.some.d.ts","sourceRoot":"","sources":["../../ts/array/array.some.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAA;AAChD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,aAAa,CAAA;AAC5C,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAA;AAC5C,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAA;AAEzD;;;;;;;;;;;;;;;;;;GAkBG;AACH,MAAM,MAAM,IAAI,CACf,CAAC,SAAS,GAAG,EAAE,EACf,QAAQ,EACR,IAAI,SAAS,QAAQ,GAAG,OAAO,GAAG,OAAO,EACzC,IAAI,GAAG,IAAI,EACX,IAAI,GAAG,KAAK,IACT,IAAI,SAAS,QAAQ,GAAG,IAAI,CAAC,MAAM,CAAC,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,CAAC,CAAA;AAEtG,yBAAiB,IAAI,CAAC;IACrB,KAAY,MAAM,CAAC,CAAC,SAAS,OAAO,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,IAAI,MAAM,SAAS,CAAC,CAAC,QAAQ,CAAC,GACvF,WAAW,CAAC,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,CAAC,GACpC,WAAW,CAAC,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,CAAC,CAAA;IAEvC,KAAY,WAAW,CAAC,CAAC,SAAS,OAAO,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,IAAI,OAAO,CAC3E,aAAa,CAAC,CAAC,CAAC,EAChB,QAAQ,EACR,IAAI,EACJ,IAAI,CACJ,CAAA;IAED,KAAY,WAAW,CAAC,CAAC,SAAS,OAAO,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,IAAI,CAAC,CAAC,QAAQ,CAAC,SAAS,CAAC,GACvF,IAAI,GACJ,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,QAAQ,CAAC,SAAS,IAAI,GACpC,IAAI,GACJ,WAAW,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,CAAC,CAAA;IAE7C,KAAY,KAAK,CAAC,CAAC,SAAS,OAAO,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,IAAI,MAAM,SAAS,CAAC,CAAC,QAAQ,CAAC,GACtF,UAAU,CAAC,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,CAAC,GACnC,UAAU,CAAC,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,CAAC,CAAA;IAEtC,KAAY,UAAU,CAAC,CAAC,SAAS,OAAO,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,IAAI,SAAS,CAC5E,aAAa,CAAC,CAAC,CAAC,EAChB,QAAQ,EACR,IAAI,EACJ,IAAI,CACJ,CAAA;IAED,KAAY,UAAU,CAAC,CAAC,SAAS,OAAO,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,IAAI,CAAC,CAAC,QAAQ,CAAC,SAAS,CAAC,GACtF,IAAI,GACJ,CAAC,CAAC,CAAC,CAAC,SAAS,QAAQ,GACrB,IAAI,GACJ,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,IAAI,CAAC,CAAA;CAC5C"}
@@ -0,0 +1,27 @@
1
+ import type { NeverType } from '../never/never_type.js';
2
+ import type { KeyTypes } from '../object/KeyTypes.js';
3
+ /**
4
+ * ⚗️ *transform*
5
+ * 🔢 *customization*
6
+ *
7
+ * Gets the common keys of the record types in the array `A`.
8
+ *
9
+ * @example
10
+ * ```ts
11
+ * import { type ArrayPlus } from 'type-plus'
12
+ *
13
+ * type R = ArrayPlus.CommonPropKeys<Array<{ a: 1 }>> // 'a'
14
+ * type R = ArrayPlus.CommonPropKeys<Array<{ a: 1, b: 1 } | { a: 1, c: 1 }>> // 'a'
15
+ * ```
16
+ *
17
+ * @typeParam Options['caseNever'] Return type when `T` is `never`.
18
+ * Default to `never`.
19
+ */
20
+ export type CommonPropKeys<A extends Record<KeyTypes, unknown>[], Options extends CommonPropKeys.Options = CommonPropKeys.DefaultOptions> = NeverType<A, Options['caseNever'], A extends Array<infer R extends Record<KeyTypes, unknown>> ? keyof R : never>;
21
+ export declare namespace CommonPropKeys {
22
+ interface Options extends NeverType.Options {
23
+ }
24
+ interface DefaultOptions extends NeverType.DefaultOptions {
25
+ }
26
+ }
27
+ //# sourceMappingURL=array_plus.common_prop_keys.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"array_plus.common_prop_keys.d.ts","sourceRoot":"","sources":["../../ts/array/array_plus.common_prop_keys.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAA;AACvD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAA;AAErD;;;;;;;;;;;;;;;;GAgBG;AACH,MAAM,MAAM,cAAc,CACzB,CAAC,SAAS,MAAM,CAAC,QAAQ,EAAE,OAAO,CAAC,EAAE,EACrC,OAAO,SAAS,cAAc,CAAC,OAAO,GAAG,cAAc,CAAC,cAAc,IACnE,SAAS,CAAC,CAAC,EACd,OAAO,CAAC,WAAW,CAAC,EACpB,CAAC,SAAS,KAAK,CAAC,MAAM,CAAC,SAAS,MAAM,CAAC,QAAQ,EAAE,OAAO,CAAC,CAAC,GAAG,MAAM,CAAC,GAAG,KAAK,CAC5E,CAAA;AAED,yBAAiB,cAAc,CAAC;IAC/B,UAAiB,OAAQ,SAAQ,SAAS,CAAC,OAAO;KACjD;IAED,UAAiB,cAAe,SAAQ,SAAS,CAAC,cAAc;KAC/D;CACD"}
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=array_plus.common_prop_keys.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"array_plus.common_prop_keys.js","sourceRoot":"","sources":["../../ts/array/array_plus.common_prop_keys.ts"],"names":[],"mappings":""}
@@ -1,4 +1,7 @@
1
1
  /**
2
+ * 🦴 *utilities
3
+ * 💀 *deprecated* Will be available only as `ArrayPlus.Concat` in the next version
4
+ *
2
5
  * Concats two arrays or tuples.
3
6
  *
4
7
  * alias of: `[...A, ...B]`
@@ -10,4 +13,4 @@
10
13
  * ```
11
14
  */
12
15
  export type Concat<A extends unknown[], B extends unknown[]> = [...A, ...B];
13
- //# sourceMappingURL=array.concat.d.ts.map
16
+ //# sourceMappingURL=array_plus.concat.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"array_plus.concat.d.ts","sourceRoot":"","sources":["../../ts/array/array_plus.concat.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AACH,MAAM,MAAM,MAAM,CAAC,CAAC,SAAS,OAAO,EAAE,EAAE,CAAC,SAAS,OAAO,EAAE,IAAI,CAAC,GAAG,CAAC,EAAE,GAAG,CAAC,CAAC,CAAA"}
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=array_plus.concat.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"array_plus.concat.js","sourceRoot":"","sources":["../../ts/array/array_plus.concat.ts"],"names":[],"mappings":""}
@@ -1,11 +1,15 @@
1
1
  export type { At } from './array.at.js';
2
- export type { Concat } from './array.concat.js';
3
2
  export type { Entries } from './array.entries.js';
4
- export type { FindFirst as Find } from './array.find.js';
5
3
  export type { FindLast } from './array.find_last.js';
6
4
  export type { Reverse } from './array.reverse.js';
7
5
  export type { Some } from './array.some.js';
8
6
  export type { IndexAt, IsIndexOutOfBound } from './array_index.js';
7
+ export type { CommonPropKeys } from './array_plus.common_prop_keys.js';
8
+ export type { Concat } from './array_plus.concat.js';
9
+ export type { DropMatch } from './array_plus.drop_match.js';
10
+ export type { ElementMatch } from './array_plus.element_match.js';
11
+ export type { Filter } from './array_plus.filter.js';
12
+ export type { Find } from './array_plus.find.js';
13
+ export type { PadStart } from './array_plus.pad_start.js';
9
14
  export type { SplitAt } from './array_plus.split_at.js';
10
- export type { PadStart } from './pad_start.js';
11
15
  //# sourceMappingURL=array_plus.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"array_plus.d.ts","sourceRoot":"","sources":["../../ts/array/array_plus.ts"],"names":[],"mappings":"AAAA,YAAY,EAAE,EAAE,EAAE,MAAM,eAAe,CAAA;AACvC,YAAY,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAA;AAC/C,YAAY,EAAE,OAAO,EAAE,MAAM,oBAAoB,CAAA;AACjD,YAAY,EAAE,SAAS,IAAI,IAAI,EAAE,MAAM,iBAAiB,CAAA;AACxD,YAAY,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAA;AACpD,YAAY,EAAE,OAAO,EAAE,MAAM,oBAAoB,CAAA;AACjD,YAAY,EAAE,IAAI,EAAE,MAAM,iBAAiB,CAAA;AAC3C,YAAY,EAAE,OAAO,EAAE,iBAAiB,EAAE,MAAM,kBAAkB,CAAA;AAClE,YAAY,EAAE,OAAO,EAAE,MAAM,0BAA0B,CAAA;AACvD,YAAY,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAA"}
1
+ {"version":3,"file":"array_plus.d.ts","sourceRoot":"","sources":["../../ts/array/array_plus.ts"],"names":[],"mappings":"AAAA,YAAY,EAAE,EAAE,EAAE,MAAM,eAAe,CAAA;AACvC,YAAY,EAAE,OAAO,EAAE,MAAM,oBAAoB,CAAA;AACjD,YAAY,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAA;AACpD,YAAY,EAAE,OAAO,EAAE,MAAM,oBAAoB,CAAA;AACjD,YAAY,EAAE,IAAI,EAAE,MAAM,iBAAiB,CAAA;AAC3C,YAAY,EAAE,OAAO,EAAE,iBAAiB,EAAE,MAAM,kBAAkB,CAAA;AAClE,YAAY,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAA;AACtE,YAAY,EAAE,MAAM,EAAE,MAAM,wBAAwB,CAAA;AACpD,YAAY,EAAE,SAAS,EAAE,MAAM,4BAA4B,CAAA;AAC3D,YAAY,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAA;AACjE,YAAY,EAAE,MAAM,EAAE,MAAM,wBAAwB,CAAA;AACpD,YAAY,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAA;AAChD,YAAY,EAAE,QAAQ,EAAE,MAAM,2BAA2B,CAAA;AACzD,YAAY,EAAE,OAAO,EAAE,MAAM,0BAA0B,CAAA"}
@@ -0,0 +1,4 @@
1
+ import type { NonNull } from '../utils/NonNull.js';
2
+ import type { NonUndefined } from '../utils/NonUndefined.js';
3
+ export type DropMatch<A extends Readonly<Array<unknown>>, Criteria> = A[0] extends Criteria ? never[] : (undefined extends Criteria ? (null extends Criteria ? Array<NonNullable<A[0]>> : Array<NonUndefined<A[0]>>) : (null extends Criteria ? Array<NonNull<A[0]>> : (Criteria extends A[0] ? Array<Exclude<A[0], Criteria>> : (A[0] extends Criteria ? A : Array<Exclude<A[0], Criteria>>))));
4
+ //# sourceMappingURL=array_plus.drop_match.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"array_plus.drop_match.d.ts","sourceRoot":"","sources":["../../ts/array/array_plus.drop_match.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAA;AAClD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAA;AAE5D,MAAM,MAAM,SAAS,CAAC,CAAC,SAAS,QAAQ,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,EAAE,QAAQ,IAAI,CAAC,CAAC,CAAC,CAAC,SAAS,QAAQ,GACxF,KAAK,EAAE,GACP,CAAC,SAAS,SAAS,QAAQ,GAC1B,CAAC,IAAI,SAAS,QAAQ,GACrB,KAAK,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,GACxB,KAAK,CAAC,YAAY,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,GAC3B,CAAC,IAAI,SAAS,QAAQ,GACrB,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,GACpB,CAAC,QAAQ,SAAS,CAAC,CAAC,CAAC,CAAC,GACrB,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,QAAQ,CAAC,CAAC,GAC9B,CAAC,CAAC,CAAC,CAAC,CAAC,SAAS,QAAQ,GACrB,CAAC,GACD,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA"}
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=array_plus.drop_match.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"array_plus.drop_match.js","sourceRoot":"","sources":["../../ts/array/array_plus.drop_match.ts"],"names":[],"mappings":""}