type-plus 8.0.0-beta.6 → 8.0.0-beta.7

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 (885) hide show
  1. package/{esm/type_plus → cjs/$type}/$resolve_options.d.ts +2 -2
  2. package/cjs/$type/$resolve_options.d.ts.map +1 -0
  3. package/cjs/$type/$resolve_options.js.map +1 -0
  4. package/cjs/$type/$type.d.ts +34 -0
  5. package/cjs/$type/$type.d.ts.map +1 -0
  6. package/cjs/{type_plus → $type}/$type.js.map +1 -1
  7. package/{esm/type_plus → cjs/$type}/branch/$branch.d.ts +3 -3
  8. package/cjs/$type/branch/$branch.d.ts.map +1 -0
  9. package/cjs/$type/branch/$branch.js.map +1 -0
  10. package/{esm/type_plus → cjs/$type}/branch/$input_options.d.ts +2 -1
  11. package/cjs/$type/branch/$input_options.d.ts.map +1 -0
  12. package/cjs/$type/branch/$input_options.js.map +1 -0
  13. package/cjs/$type/branch/$resolve_branch.d.ts +22 -0
  14. package/cjs/$type/branch/$resolve_branch.d.ts.map +1 -0
  15. package/cjs/$type/branch/$resolve_branch.js.map +1 -0
  16. package/cjs/$type/branch/$selection.d.ts +161 -0
  17. package/cjs/$type/branch/$selection.d.ts.map +1 -0
  18. package/cjs/$type/branch/$selection.js.map +1 -0
  19. package/cjs/$type/distributive/$distributive.d.ts +27 -0
  20. package/cjs/$type/distributive/$distributive.d.ts.map +1 -0
  21. package/cjs/$type/distributive/$distributive.js.map +1 -0
  22. package/cjs/$type/errors/$error.d.ts +23 -0
  23. package/cjs/$type/errors/$error.d.ts.map +1 -0
  24. package/cjs/{type_plus → $type/errors}/$error.js.map +1 -1
  25. package/{esm/type_plus → cjs/$type/errors}/$infer_error.d.ts +7 -6
  26. package/cjs/$type/errors/$infer_error.d.ts.map +1 -0
  27. package/cjs/$type/errors/$infer_error.js.map +1 -0
  28. package/{esm/type → cjs/$type/errors}/failed.d.ts +4 -0
  29. package/cjs/$type/errors/failed.d.ts.map +1 -0
  30. package/cjs/{type → $type/errors}/failed.js.map +1 -1
  31. package/cjs/$type/exact/$exact.d.ts +27 -0
  32. package/cjs/$type/exact/$exact.d.ts.map +1 -0
  33. package/cjs/{type_plus/branch → $type/exact}/$exact.js.map +1 -1
  34. package/cjs/$type/special/$any.d.ts +36 -0
  35. package/cjs/$type/special/$any.d.ts.map +1 -0
  36. package/cjs/{any/any.js → $type/special/$any.js} +1 -1
  37. package/cjs/$type/special/$any.js.map +1 -0
  38. package/cjs/$type/special/$never.d.ts +52 -0
  39. package/cjs/$type/special/$never.d.ts.map +1 -0
  40. package/cjs/$type/special/$never.js +3 -0
  41. package/cjs/$type/special/$never.js.map +1 -0
  42. package/cjs/$type/special/$special.d.ts +31 -0
  43. package/cjs/$type/special/$special.d.ts.map +1 -0
  44. package/cjs/$type/special/$special.js +3 -0
  45. package/cjs/$type/special/$special.js.map +1 -0
  46. package/cjs/$type/special/$unknown.d.ts +37 -0
  47. package/cjs/$type/special/$unknown.d.ts.map +1 -0
  48. package/cjs/$type/special/$unknown.js +3 -0
  49. package/cjs/$type/special/$unknown.js.map +1 -0
  50. package/cjs/$type/special/$void.d.ts +46 -0
  51. package/cjs/$type/special/$void.d.ts.map +1 -0
  52. package/cjs/{never/never.js → $type/special/$void.js} +1 -1
  53. package/cjs/$type/special/$void.js.map +1 -0
  54. package/cjs/$type/utils/$merge_options.d.ts +14 -0
  55. package/cjs/$type/utils/$merge_options.d.ts.map +1 -0
  56. package/cjs/$type/utils/$merge_options.js.map +1 -0
  57. package/cjs/any/is_any.d.ts +23 -20
  58. package/cjs/any/is_any.d.ts.map +1 -1
  59. package/cjs/any/is_not_any.d.ts +15 -14
  60. package/cjs/any/is_not_any.d.ts.map +1 -1
  61. package/cjs/array/array.some.d.ts +1 -1
  62. package/cjs/array/array.some.d.ts.map +1 -1
  63. package/cjs/array/array_plus.common_prop_keys.d.ts +1 -1
  64. package/cjs/array/array_plus.common_prop_keys.d.ts.map +1 -1
  65. package/cjs/array/array_plus.filter.d.ts +2 -2
  66. package/cjs/array/array_plus.filter.d.ts.map +1 -1
  67. package/cjs/array/array_plus.find.d.ts +2 -2
  68. package/cjs/array/array_plus.find.d.ts.map +1 -1
  69. package/cjs/array/array_plus.index_at.d.ts +16 -10
  70. package/cjs/array/array_plus.index_at.d.ts.map +1 -1
  71. package/cjs/array/array_plus.index_at.js.map +1 -1
  72. package/cjs/array/array_plus.is_readonly.d.ts +3 -3
  73. package/cjs/array/array_plus.is_readonly.d.ts.map +1 -1
  74. package/cjs/array/head.d.ts +3 -3
  75. package/cjs/array/head.d.ts.map +1 -1
  76. package/cjs/array/is_array.d.ts +23 -19
  77. package/cjs/array/is_array.d.ts.map +1 -1
  78. package/cjs/array/is_not_array.d.ts +23 -19
  79. package/cjs/array/is_not_array.d.ts.map +1 -1
  80. package/cjs/array/last.d.ts +5 -3
  81. package/cjs/array/last.d.ts.map +1 -1
  82. package/cjs/assertion/assert_type.d.ts.map +1 -1
  83. package/cjs/bigint/is_bigint.d.ts +20 -16
  84. package/cjs/bigint/is_bigint.d.ts.map +1 -1
  85. package/cjs/bigint/is_bigint_literal.d.ts +18 -13
  86. package/cjs/bigint/is_bigint_literal.d.ts.map +1 -1
  87. package/cjs/bigint/is_not_bigint.d.ts +20 -16
  88. package/cjs/bigint/is_not_bigint.d.ts.map +1 -1
  89. package/cjs/bigint/is_not_bigint_literal.d.ts +19 -13
  90. package/cjs/bigint/is_not_bigint_literal.d.ts.map +1 -1
  91. package/cjs/binary/_binary.d.ts +2 -1
  92. package/cjs/binary/_binary.d.ts.map +1 -1
  93. package/cjs/binary/_binary.js +3 -0
  94. package/cjs/binary/_binary.js.map +1 -1
  95. package/cjs/binary/bit.d.ts +26 -0
  96. package/cjs/binary/bit.d.ts.map +1 -0
  97. package/cjs/binary/{Bit.js → bit.js} +1 -1
  98. package/cjs/binary/bit.js.map +1 -0
  99. package/cjs/boolean/is_boolean.d.ts +20 -16
  100. package/cjs/boolean/is_boolean.d.ts.map +1 -1
  101. package/cjs/boolean/is_false.d.ts +15 -9
  102. package/cjs/boolean/is_false.d.ts.map +1 -1
  103. package/cjs/boolean/is_not_boolean.d.ts +21 -16
  104. package/cjs/boolean/is_not_boolean.d.ts.map +1 -1
  105. package/cjs/boolean/is_not_false.d.ts +16 -9
  106. package/cjs/boolean/is_not_false.d.ts.map +1 -1
  107. package/cjs/boolean/is_not_true.d.ts +15 -9
  108. package/cjs/boolean/is_not_true.d.ts.map +1 -1
  109. package/cjs/boolean/is_true.d.ts +15 -9
  110. package/cjs/boolean/is_true.d.ts.map +1 -1
  111. package/cjs/equal/equal.d.ts +189 -74
  112. package/cjs/equal/equal.d.ts.map +1 -1
  113. package/cjs/equal/identity_equal.d.ts +5 -1
  114. package/cjs/equal/identity_equal.d.ts.map +1 -1
  115. package/cjs/equal/is_equal.d.ts +102 -0
  116. package/cjs/equal/is_equal.d.ts.map +1 -0
  117. package/cjs/equal/is_equal.js +3 -0
  118. package/cjs/equal/is_equal.js.map +1 -0
  119. package/cjs/function/is_function.d.ts +28 -5
  120. package/cjs/function/is_function.d.ts.map +1 -1
  121. package/cjs/function/is_not_function.d.ts +1 -1
  122. package/cjs/function/is_not_function.d.ts.map +1 -1
  123. package/cjs/function/is_not_strict_function.d.ts +15 -13
  124. package/cjs/function/is_not_strict_function.d.ts.map +1 -1
  125. package/cjs/function/is_strict_function.d.ts +22 -17
  126. package/cjs/function/is_strict_function.d.ts.map +1 -1
  127. package/cjs/functional/Maybe.d.ts +1 -1
  128. package/cjs/functional/Maybe.d.ts.map +1 -1
  129. package/cjs/functional/compose.d.ts.map +1 -1
  130. package/cjs/functional/compose.js +1 -3
  131. package/cjs/functional/compose.js.map +1 -1
  132. package/cjs/index.d.ts +20 -21
  133. package/cjs/index.d.ts.map +1 -1
  134. package/cjs/index.js.map +1 -1
  135. package/cjs/logical/logical.d.ts +35 -0
  136. package/cjs/logical/logical.d.ts.map +1 -0
  137. package/cjs/{predicates → logical}/logical.js.map +1 -1
  138. package/cjs/math/abs.d.ts +1 -1
  139. package/cjs/math/abs.d.ts.map +1 -1
  140. package/cjs/mix_types/box.d.ts +2 -2
  141. package/cjs/mix_types/box.d.ts.map +1 -1
  142. package/cjs/mix_types/is_any_or_never.d.ts +2 -3
  143. package/cjs/mix_types/is_any_or_never.d.ts.map +1 -1
  144. package/cjs/mix_types/merge.d.ts +18 -6
  145. package/cjs/mix_types/merge.d.ts.map +1 -1
  146. package/cjs/mix_types/merge.js.map +1 -1
  147. package/cjs/never/is_never.d.ts +16 -15
  148. package/cjs/never/is_never.d.ts.map +1 -1
  149. package/cjs/never/is_not_never.d.ts +16 -15
  150. package/cjs/never/is_not_never.d.ts.map +1 -1
  151. package/cjs/null/is_not_null.d.ts +15 -9
  152. package/cjs/null/is_not_null.d.ts.map +1 -1
  153. package/cjs/null/is_null.d.ts +15 -9
  154. package/cjs/null/is_null.d.ts.map +1 -1
  155. package/cjs/number/is_not_number.d.ts +20 -16
  156. package/cjs/number/is_not_number.d.ts.map +1 -1
  157. package/cjs/number/is_not_number_literal.d.ts +18 -13
  158. package/cjs/number/is_not_number_literal.d.ts.map +1 -1
  159. package/cjs/number/is_number.d.ts +20 -16
  160. package/cjs/number/is_number.d.ts.map +1 -1
  161. package/cjs/number/is_number_literal.d.ts +18 -13
  162. package/cjs/number/is_number_literal.d.ts.map +1 -1
  163. package/cjs/numeric/is_integer.d.ts +18 -12
  164. package/cjs/numeric/is_integer.d.ts.map +1 -1
  165. package/cjs/numeric/is_negative.d.ts +19 -13
  166. package/cjs/numeric/is_negative.d.ts.map +1 -1
  167. package/cjs/numeric/is_not_integer.d.ts +13 -7
  168. package/cjs/numeric/is_not_integer.d.ts.map +1 -1
  169. package/cjs/numeric/is_not_negative.d.ts +15 -9
  170. package/cjs/numeric/is_not_negative.d.ts.map +1 -1
  171. package/cjs/numeric/is_not_numeric.d.ts +1 -1
  172. package/cjs/numeric/is_not_numeric.d.ts.map +1 -1
  173. package/cjs/numeric/is_not_positive.d.ts +13 -7
  174. package/cjs/numeric/is_not_positive.d.ts.map +1 -1
  175. package/cjs/numeric/is_numeric.d.ts +28 -5
  176. package/cjs/numeric/is_numeric.d.ts.map +1 -1
  177. package/cjs/numeric/is_positive.d.ts +19 -13
  178. package/cjs/numeric/is_positive.d.ts.map +1 -1
  179. package/cjs/object/ANotB.d.ts +2 -2
  180. package/cjs/object/ANotB.d.ts.map +1 -1
  181. package/cjs/object/KeysWithDiffType.d.ts +1 -1
  182. package/cjs/object/KeysWithDiffType.d.ts.map +1 -1
  183. package/cjs/object/adjust_exact_optional_props.d.ts +1 -1
  184. package/cjs/object/adjust_exact_optional_props.d.ts.map +1 -1
  185. package/cjs/object/is_not_object.d.ts +23 -19
  186. package/cjs/object/is_not_object.d.ts.map +1 -1
  187. package/cjs/object/is_object.d.ts +23 -19
  188. package/cjs/object/is_object.d.ts.map +1 -1
  189. package/cjs/object/left_join.d.ts +2 -2
  190. package/cjs/object/left_join.d.ts.map +1 -1
  191. package/cjs/object/mapProperties.d.ts +1 -1
  192. package/cjs/object/mapProperties.d.ts.map +1 -1
  193. package/cjs/object/mapProperties.js.map +1 -1
  194. package/cjs/object/merge.d.ts +55 -49
  195. package/cjs/object/merge.d.ts.map +1 -1
  196. package/cjs/object/optional_key.d.ts +1 -1
  197. package/cjs/object/optional_key.d.ts.map +1 -1
  198. package/cjs/object/record.d.ts.map +1 -1
  199. package/cjs/object/split.d.ts +1 -1
  200. package/cjs/object/split.d.ts.map +1 -1
  201. package/cjs/predicates/CanAssign.d.ts +1 -1
  202. package/cjs/predicates/CanAssign.d.ts.map +1 -1
  203. package/cjs/predicates/assignable.d.ts +23 -25
  204. package/cjs/predicates/assignable.d.ts.map +1 -1
  205. package/cjs/predicates/index.d.ts +1 -1
  206. package/cjs/predicates/index.d.ts.map +1 -1
  207. package/cjs/predicates/not_assignable.d.ts +24 -26
  208. package/cjs/predicates/not_assignable.d.ts.map +1 -1
  209. package/cjs/string/is_not_string.d.ts +20 -17
  210. package/cjs/string/is_not_string.d.ts.map +1 -1
  211. package/cjs/string/is_not_string_literal.d.ts +25 -22
  212. package/cjs/string/is_not_string_literal.d.ts.map +1 -1
  213. package/cjs/string/is_not_template_literal.d.ts +18 -13
  214. package/cjs/string/is_not_template_literal.d.ts.map +1 -1
  215. package/cjs/string/is_string.d.ts +20 -16
  216. package/cjs/string/is_string.d.ts.map +1 -1
  217. package/cjs/string/is_string_literal.d.ts +25 -22
  218. package/cjs/string/is_string_literal.d.ts.map +1 -1
  219. package/cjs/string/is_template_literal.d.ts +18 -13
  220. package/cjs/string/is_template_literal.d.ts.map +1 -1
  221. package/cjs/symbol/is_not_symbol.d.ts +15 -9
  222. package/cjs/symbol/is_not_symbol.d.ts.map +1 -1
  223. package/cjs/symbol/is_symbol.d.ts +15 -9
  224. package/cjs/symbol/is_symbol.d.ts.map +1 -1
  225. package/cjs/testing/stub.d.ts +0 -1
  226. package/cjs/testing/stub.d.ts.map +1 -1
  227. package/cjs/testing/stub.js.map +1 -1
  228. package/cjs/testing/test_type.d.ts +1 -1
  229. package/cjs/testing/test_type.d.ts.map +1 -1
  230. package/cjs/tuple/is_not_tuple.d.ts +18 -13
  231. package/cjs/tuple/is_not_tuple.d.ts.map +1 -1
  232. package/cjs/tuple/is_tuple.d.ts +18 -13
  233. package/cjs/tuple/is_tuple.d.ts.map +1 -1
  234. package/cjs/tuple/tuple_plus.common_prop_keys.d.ts +1 -1
  235. package/cjs/tuple/tuple_plus.common_prop_keys.d.ts.map +1 -1
  236. package/cjs/tuple/tuple_plus.drop_match.d.ts +1 -1
  237. package/cjs/tuple/tuple_plus.drop_match.d.ts.map +1 -1
  238. package/cjs/tuple/tuple_plus.find.d.ts +1 -1
  239. package/cjs/tuple/tuple_plus.find.d.ts.map +1 -1
  240. package/cjs/type-guard/is_type.d.ts +1 -1
  241. package/cjs/type-guard/is_type.d.ts.map +1 -1
  242. package/cjs/undefined/has_undefined.d.ts +4 -5
  243. package/cjs/undefined/has_undefined.d.ts.map +1 -1
  244. package/cjs/undefined/is_not_undefined.d.ts +15 -9
  245. package/cjs/undefined/is_not_undefined.d.ts.map +1 -1
  246. package/cjs/undefined/is_undefined.d.ts +15 -9
  247. package/cjs/undefined/is_undefined.d.ts.map +1 -1
  248. package/cjs/unknown/is_not_unknown.d.ts +15 -14
  249. package/cjs/unknown/is_not_unknown.d.ts.map +1 -1
  250. package/cjs/unknown/is_unknown.d.ts +15 -14
  251. package/cjs/unknown/is_unknown.d.ts.map +1 -1
  252. package/cjs/unknown/not_unknown_or.d.ts +1 -1
  253. package/cjs/unknown/not_unknown_or.d.ts.map +1 -1
  254. package/cjs/utils/Widen.d.ts +9 -2
  255. package/cjs/utils/Widen.d.ts.map +1 -1
  256. package/cjs/utils/excessive.d.ts +12 -0
  257. package/cjs/utils/excessive.d.ts.map +1 -0
  258. package/cjs/utils/excessive.js +3 -0
  259. package/cjs/utils/excessive.js.map +1 -0
  260. package/cjs/{type → utils}/no_infer.d.ts +9 -7
  261. package/cjs/utils/no_infer.d.ts.map +1 -0
  262. package/cjs/{type → utils}/no_infer.js.map +1 -1
  263. package/cjs/void/is_not_void.d.ts +17 -10
  264. package/cjs/void/is_not_void.d.ts.map +1 -1
  265. package/cjs/void/is_void.d.ts +17 -10
  266. package/cjs/void/is_void.d.ts.map +1 -1
  267. package/{cjs/type_plus → esm/$type}/$resolve_options.d.ts +2 -2
  268. package/esm/$type/$resolve_options.d.ts.map +1 -0
  269. package/esm/$type/$resolve_options.js.map +1 -0
  270. package/esm/$type/$type.d.ts +34 -0
  271. package/esm/$type/$type.d.ts.map +1 -0
  272. package/esm/{type_plus → $type}/$type.js.map +1 -1
  273. package/{cjs/type_plus → esm/$type}/branch/$branch.d.ts +3 -3
  274. package/esm/$type/branch/$branch.d.ts.map +1 -0
  275. package/esm/$type/branch/$branch.js.map +1 -0
  276. package/{cjs/type_plus → esm/$type}/branch/$input_options.d.ts +2 -1
  277. package/esm/$type/branch/$input_options.d.ts.map +1 -0
  278. package/esm/$type/branch/$input_options.js.map +1 -0
  279. package/esm/$type/branch/$resolve_branch.d.ts +22 -0
  280. package/esm/$type/branch/$resolve_branch.d.ts.map +1 -0
  281. package/esm/$type/branch/$resolve_branch.js.map +1 -0
  282. package/esm/$type/branch/$selection.d.ts +161 -0
  283. package/esm/$type/branch/$selection.d.ts.map +1 -0
  284. package/esm/$type/branch/$selection.js.map +1 -0
  285. package/esm/$type/distributive/$distributive.d.ts +27 -0
  286. package/esm/$type/distributive/$distributive.d.ts.map +1 -0
  287. package/esm/$type/distributive/$distributive.js.map +1 -0
  288. package/esm/$type/errors/$error.d.ts +23 -0
  289. package/esm/$type/errors/$error.d.ts.map +1 -0
  290. package/esm/{type_plus → $type/errors}/$error.js.map +1 -1
  291. package/{cjs/type_plus → esm/$type/errors}/$infer_error.d.ts +7 -6
  292. package/esm/$type/errors/$infer_error.d.ts.map +1 -0
  293. package/esm/$type/errors/$infer_error.js.map +1 -0
  294. package/{cjs/type → esm/$type/errors}/failed.d.ts +4 -0
  295. package/esm/$type/errors/failed.d.ts.map +1 -0
  296. package/esm/{type → $type/errors}/failed.js.map +1 -1
  297. package/esm/$type/exact/$exact.d.ts +27 -0
  298. package/esm/$type/exact/$exact.d.ts.map +1 -0
  299. package/esm/{type_plus/branch → $type/exact}/$exact.js.map +1 -1
  300. package/esm/$type/special/$any.d.ts +36 -0
  301. package/esm/$type/special/$any.d.ts.map +1 -0
  302. package/esm/$type/special/$any.js +2 -0
  303. package/esm/$type/special/$any.js.map +1 -0
  304. package/esm/$type/special/$never.d.ts +52 -0
  305. package/esm/$type/special/$never.d.ts.map +1 -0
  306. package/esm/$type/special/$never.js +2 -0
  307. package/esm/$type/special/$never.js.map +1 -0
  308. package/esm/$type/special/$special.d.ts +31 -0
  309. package/esm/$type/special/$special.d.ts.map +1 -0
  310. package/esm/$type/special/$special.js +2 -0
  311. package/esm/$type/special/$special.js.map +1 -0
  312. package/esm/$type/special/$unknown.d.ts +37 -0
  313. package/esm/$type/special/$unknown.d.ts.map +1 -0
  314. package/esm/$type/special/$unknown.js +2 -0
  315. package/esm/$type/special/$unknown.js.map +1 -0
  316. package/esm/$type/special/$void.d.ts +46 -0
  317. package/esm/$type/special/$void.d.ts.map +1 -0
  318. package/esm/$type/special/$void.js +2 -0
  319. package/esm/$type/special/$void.js.map +1 -0
  320. package/esm/$type/utils/$merge_options.d.ts +14 -0
  321. package/esm/$type/utils/$merge_options.d.ts.map +1 -0
  322. package/esm/$type/utils/$merge_options.js.map +1 -0
  323. package/esm/any/is_any.d.ts +23 -20
  324. package/esm/any/is_any.d.ts.map +1 -1
  325. package/esm/any/is_not_any.d.ts +15 -14
  326. package/esm/any/is_not_any.d.ts.map +1 -1
  327. package/esm/array/array.some.d.ts +1 -1
  328. package/esm/array/array.some.d.ts.map +1 -1
  329. package/esm/array/array_plus.common_prop_keys.d.ts +1 -1
  330. package/esm/array/array_plus.common_prop_keys.d.ts.map +1 -1
  331. package/esm/array/array_plus.filter.d.ts +2 -2
  332. package/esm/array/array_plus.filter.d.ts.map +1 -1
  333. package/esm/array/array_plus.find.d.ts +2 -2
  334. package/esm/array/array_plus.find.d.ts.map +1 -1
  335. package/esm/array/array_plus.index_at.d.ts +16 -10
  336. package/esm/array/array_plus.index_at.d.ts.map +1 -1
  337. package/esm/array/array_plus.index_at.js.map +1 -1
  338. package/esm/array/array_plus.is_readonly.d.ts +3 -3
  339. package/esm/array/array_plus.is_readonly.d.ts.map +1 -1
  340. package/esm/array/head.d.ts +3 -3
  341. package/esm/array/head.d.ts.map +1 -1
  342. package/esm/array/is_array.d.ts +23 -19
  343. package/esm/array/is_array.d.ts.map +1 -1
  344. package/esm/array/is_not_array.d.ts +23 -19
  345. package/esm/array/is_not_array.d.ts.map +1 -1
  346. package/esm/array/last.d.ts +5 -3
  347. package/esm/array/last.d.ts.map +1 -1
  348. package/esm/assertion/assert_type.d.ts.map +1 -1
  349. package/esm/assertion/assert_type.js.map +1 -1
  350. package/esm/bigint/is_bigint.d.ts +20 -16
  351. package/esm/bigint/is_bigint.d.ts.map +1 -1
  352. package/esm/bigint/is_bigint_literal.d.ts +18 -13
  353. package/esm/bigint/is_bigint_literal.d.ts.map +1 -1
  354. package/esm/bigint/is_not_bigint.d.ts +20 -16
  355. package/esm/bigint/is_not_bigint.d.ts.map +1 -1
  356. package/esm/bigint/is_not_bigint_literal.d.ts +19 -13
  357. package/esm/bigint/is_not_bigint_literal.d.ts.map +1 -1
  358. package/esm/binary/_binary.d.ts +2 -1
  359. package/esm/binary/_binary.d.ts.map +1 -1
  360. package/esm/binary/_binary.js +2 -1
  361. package/esm/binary/_binary.js.map +1 -1
  362. package/esm/binary/bit.d.ts +26 -0
  363. package/esm/binary/bit.d.ts.map +1 -0
  364. package/esm/binary/bit.js +2 -0
  365. package/esm/binary/bit.js.map +1 -0
  366. package/esm/boolean/is_boolean.d.ts +20 -16
  367. package/esm/boolean/is_boolean.d.ts.map +1 -1
  368. package/esm/boolean/is_false.d.ts +15 -9
  369. package/esm/boolean/is_false.d.ts.map +1 -1
  370. package/esm/boolean/is_not_boolean.d.ts +21 -16
  371. package/esm/boolean/is_not_boolean.d.ts.map +1 -1
  372. package/esm/boolean/is_not_false.d.ts +16 -9
  373. package/esm/boolean/is_not_false.d.ts.map +1 -1
  374. package/esm/boolean/is_not_true.d.ts +15 -9
  375. package/esm/boolean/is_not_true.d.ts.map +1 -1
  376. package/esm/boolean/is_true.d.ts +15 -9
  377. package/esm/boolean/is_true.d.ts.map +1 -1
  378. package/esm/equal/equal.d.ts +189 -74
  379. package/esm/equal/equal.d.ts.map +1 -1
  380. package/esm/equal/identity_equal.d.ts +5 -1
  381. package/esm/equal/identity_equal.d.ts.map +1 -1
  382. package/esm/equal/is_equal.d.ts +102 -0
  383. package/esm/equal/is_equal.d.ts.map +1 -0
  384. package/esm/equal/is_equal.js +2 -0
  385. package/esm/equal/is_equal.js.map +1 -0
  386. package/esm/function/is_function.d.ts +28 -5
  387. package/esm/function/is_function.d.ts.map +1 -1
  388. package/esm/function/is_not_function.d.ts +1 -1
  389. package/esm/function/is_not_function.d.ts.map +1 -1
  390. package/esm/function/is_not_strict_function.d.ts +15 -13
  391. package/esm/function/is_not_strict_function.d.ts.map +1 -1
  392. package/esm/function/is_strict_function.d.ts +22 -17
  393. package/esm/function/is_strict_function.d.ts.map +1 -1
  394. package/esm/functional/Maybe.d.ts +1 -1
  395. package/esm/functional/Maybe.d.ts.map +1 -1
  396. package/esm/functional/compose.d.ts.map +1 -1
  397. package/esm/functional/compose.js +1 -3
  398. package/esm/functional/compose.js.map +1 -1
  399. package/esm/index.d.ts +20 -21
  400. package/esm/index.d.ts.map +1 -1
  401. package/esm/index.js.map +1 -1
  402. package/esm/logical/logical.d.ts +35 -0
  403. package/esm/logical/logical.d.ts.map +1 -0
  404. package/esm/{predicates → logical}/logical.js.map +1 -1
  405. package/esm/math/abs.d.ts +1 -1
  406. package/esm/math/abs.d.ts.map +1 -1
  407. package/esm/mix_types/box.d.ts +2 -2
  408. package/esm/mix_types/box.d.ts.map +1 -1
  409. package/esm/mix_types/is_any_or_never.d.ts +2 -3
  410. package/esm/mix_types/is_any_or_never.d.ts.map +1 -1
  411. package/esm/mix_types/merge.d.ts +18 -6
  412. package/esm/mix_types/merge.d.ts.map +1 -1
  413. package/esm/mix_types/merge.js.map +1 -1
  414. package/esm/never/is_never.d.ts +16 -15
  415. package/esm/never/is_never.d.ts.map +1 -1
  416. package/esm/never/is_not_never.d.ts +16 -15
  417. package/esm/never/is_not_never.d.ts.map +1 -1
  418. package/esm/null/is_not_null.d.ts +15 -9
  419. package/esm/null/is_not_null.d.ts.map +1 -1
  420. package/esm/null/is_null.d.ts +15 -9
  421. package/esm/null/is_null.d.ts.map +1 -1
  422. package/esm/number/is_not_number.d.ts +20 -16
  423. package/esm/number/is_not_number.d.ts.map +1 -1
  424. package/esm/number/is_not_number_literal.d.ts +18 -13
  425. package/esm/number/is_not_number_literal.d.ts.map +1 -1
  426. package/esm/number/is_number.d.ts +20 -16
  427. package/esm/number/is_number.d.ts.map +1 -1
  428. package/esm/number/is_number_literal.d.ts +18 -13
  429. package/esm/number/is_number_literal.d.ts.map +1 -1
  430. package/esm/numeric/is_integer.d.ts +18 -12
  431. package/esm/numeric/is_integer.d.ts.map +1 -1
  432. package/esm/numeric/is_negative.d.ts +19 -13
  433. package/esm/numeric/is_negative.d.ts.map +1 -1
  434. package/esm/numeric/is_not_integer.d.ts +13 -7
  435. package/esm/numeric/is_not_integer.d.ts.map +1 -1
  436. package/esm/numeric/is_not_negative.d.ts +15 -9
  437. package/esm/numeric/is_not_negative.d.ts.map +1 -1
  438. package/esm/numeric/is_not_numeric.d.ts +1 -1
  439. package/esm/numeric/is_not_numeric.d.ts.map +1 -1
  440. package/esm/numeric/is_not_positive.d.ts +13 -7
  441. package/esm/numeric/is_not_positive.d.ts.map +1 -1
  442. package/esm/numeric/is_numeric.d.ts +28 -5
  443. package/esm/numeric/is_numeric.d.ts.map +1 -1
  444. package/esm/numeric/is_positive.d.ts +19 -13
  445. package/esm/numeric/is_positive.d.ts.map +1 -1
  446. package/esm/object/ANotB.d.ts +2 -2
  447. package/esm/object/ANotB.d.ts.map +1 -1
  448. package/esm/object/KeysWithDiffType.d.ts +1 -1
  449. package/esm/object/KeysWithDiffType.d.ts.map +1 -1
  450. package/esm/object/adjust_exact_optional_props.d.ts +1 -1
  451. package/esm/object/adjust_exact_optional_props.d.ts.map +1 -1
  452. package/esm/object/is_not_object.d.ts +23 -19
  453. package/esm/object/is_not_object.d.ts.map +1 -1
  454. package/esm/object/is_object.d.ts +23 -19
  455. package/esm/object/is_object.d.ts.map +1 -1
  456. package/esm/object/left_join.d.ts +2 -2
  457. package/esm/object/left_join.d.ts.map +1 -1
  458. package/esm/object/mapProperties.d.ts +1 -1
  459. package/esm/object/mapProperties.d.ts.map +1 -1
  460. package/esm/object/mapProperties.js.map +1 -1
  461. package/esm/object/merge.d.ts +55 -49
  462. package/esm/object/merge.d.ts.map +1 -1
  463. package/esm/object/optional_key.d.ts +1 -1
  464. package/esm/object/optional_key.d.ts.map +1 -1
  465. package/esm/object/record.d.ts.map +1 -1
  466. package/esm/object/split.d.ts +1 -1
  467. package/esm/object/split.d.ts.map +1 -1
  468. package/esm/predicates/CanAssign.d.ts +1 -1
  469. package/esm/predicates/CanAssign.d.ts.map +1 -1
  470. package/esm/predicates/assignable.d.ts +23 -25
  471. package/esm/predicates/assignable.d.ts.map +1 -1
  472. package/esm/predicates/index.d.ts +1 -1
  473. package/esm/predicates/index.d.ts.map +1 -1
  474. package/esm/predicates/not_assignable.d.ts +24 -26
  475. package/esm/predicates/not_assignable.d.ts.map +1 -1
  476. package/esm/string/is_not_string.d.ts +20 -17
  477. package/esm/string/is_not_string.d.ts.map +1 -1
  478. package/esm/string/is_not_string_literal.d.ts +25 -22
  479. package/esm/string/is_not_string_literal.d.ts.map +1 -1
  480. package/esm/string/is_not_template_literal.d.ts +18 -13
  481. package/esm/string/is_not_template_literal.d.ts.map +1 -1
  482. package/esm/string/is_string.d.ts +20 -16
  483. package/esm/string/is_string.d.ts.map +1 -1
  484. package/esm/string/is_string_literal.d.ts +25 -22
  485. package/esm/string/is_string_literal.d.ts.map +1 -1
  486. package/esm/string/is_template_literal.d.ts +18 -13
  487. package/esm/string/is_template_literal.d.ts.map +1 -1
  488. package/esm/symbol/is_not_symbol.d.ts +15 -9
  489. package/esm/symbol/is_not_symbol.d.ts.map +1 -1
  490. package/esm/symbol/is_symbol.d.ts +15 -9
  491. package/esm/symbol/is_symbol.d.ts.map +1 -1
  492. package/esm/testing/stub.d.ts +0 -1
  493. package/esm/testing/stub.d.ts.map +1 -1
  494. package/esm/testing/stub.js.map +1 -1
  495. package/esm/testing/test_type.d.ts +1 -1
  496. package/esm/testing/test_type.d.ts.map +1 -1
  497. package/esm/tuple/is_not_tuple.d.ts +18 -13
  498. package/esm/tuple/is_not_tuple.d.ts.map +1 -1
  499. package/esm/tuple/is_tuple.d.ts +18 -13
  500. package/esm/tuple/is_tuple.d.ts.map +1 -1
  501. package/esm/tuple/tuple_plus.common_prop_keys.d.ts +1 -1
  502. package/esm/tuple/tuple_plus.common_prop_keys.d.ts.map +1 -1
  503. package/esm/tuple/tuple_plus.drop_match.d.ts +1 -1
  504. package/esm/tuple/tuple_plus.drop_match.d.ts.map +1 -1
  505. package/esm/tuple/tuple_plus.find.d.ts +1 -1
  506. package/esm/tuple/tuple_plus.find.d.ts.map +1 -1
  507. package/esm/type-guard/is_type.d.ts +1 -1
  508. package/esm/type-guard/is_type.d.ts.map +1 -1
  509. package/esm/undefined/has_undefined.d.ts +4 -5
  510. package/esm/undefined/has_undefined.d.ts.map +1 -1
  511. package/esm/undefined/is_not_undefined.d.ts +15 -9
  512. package/esm/undefined/is_not_undefined.d.ts.map +1 -1
  513. package/esm/undefined/is_undefined.d.ts +15 -9
  514. package/esm/undefined/is_undefined.d.ts.map +1 -1
  515. package/esm/unknown/is_not_unknown.d.ts +15 -14
  516. package/esm/unknown/is_not_unknown.d.ts.map +1 -1
  517. package/esm/unknown/is_unknown.d.ts +15 -14
  518. package/esm/unknown/is_unknown.d.ts.map +1 -1
  519. package/esm/unknown/not_unknown_or.d.ts +1 -1
  520. package/esm/unknown/not_unknown_or.d.ts.map +1 -1
  521. package/esm/utils/Widen.d.ts +9 -2
  522. package/esm/utils/Widen.d.ts.map +1 -1
  523. package/esm/utils/excessive.d.ts +12 -0
  524. package/esm/utils/excessive.d.ts.map +1 -0
  525. package/esm/utils/excessive.js +2 -0
  526. package/esm/utils/excessive.js.map +1 -0
  527. package/esm/{type → utils}/no_infer.d.ts +9 -7
  528. package/esm/utils/no_infer.d.ts.map +1 -0
  529. package/esm/{type → utils}/no_infer.js.map +1 -1
  530. package/esm/void/is_not_void.d.ts +17 -10
  531. package/esm/void/is_not_void.d.ts.map +1 -1
  532. package/esm/void/is_void.d.ts +17 -10
  533. package/esm/void/is_void.d.ts.map +1 -1
  534. package/package.json +5 -5
  535. package/readme.md +74 -74
  536. package/src/{type_plus → $type}/$resolve_options.ts +4 -2
  537. package/src/$type/$type.ts +37 -0
  538. package/src/{type_plus → $type}/branch/$branch.ts +4 -2
  539. package/src/{type_plus → $type}/branch/$input_options.ts +2 -1
  540. package/src/$type/branch/$resolve_branch.ts +46 -0
  541. package/src/$type/branch/$selection.ts +170 -0
  542. package/src/$type/branch/readme.md +78 -0
  543. package/src/$type/distributive/$distributive.ts +34 -0
  544. package/src/$type/distributive/readme.md +26 -0
  545. package/src/$type/errors/$error.ts +20 -0
  546. package/src/{type_plus → $type/errors}/$infer_error.ts +7 -8
  547. package/src/{type → $type/errors}/failed.ts +4 -0
  548. package/src/$type/errors/readme.md +60 -0
  549. package/src/$type/exact/$exact.ts +34 -0
  550. package/src/$type/exact/readme.md +27 -0
  551. package/src/$type/readme.md +23 -0
  552. package/src/$type/special/$any.ts +34 -0
  553. package/src/$type/special/$never.ts +51 -0
  554. package/src/$type/special/$special.ts +40 -0
  555. package/src/$type/special/$unknown.ts +35 -0
  556. package/src/$type/special/$void.ts +44 -0
  557. package/src/$type/special/readme.md +51 -0
  558. package/src/$type/utils/$merge_options.ts +11 -0
  559. package/src/$type/utils/readme.md +10 -0
  560. package/src/any/is_any.ts +23 -20
  561. package/src/any/is_not_any.ts +15 -14
  562. package/src/any/readme.md +30 -19
  563. package/src/array/array.some.ts +1 -1
  564. package/src/array/array_plus.common_prop_keys.ts +1 -1
  565. package/src/array/array_plus.filter.ts +2 -2
  566. package/src/array/array_plus.find.ts +2 -2
  567. package/src/array/array_plus.index_at.ts +23 -29
  568. package/src/array/array_plus.is_readonly.ts +3 -3
  569. package/src/array/head.ts +3 -3
  570. package/src/array/is_array.ts +30 -23
  571. package/src/array/is_not_array.ts +30 -23
  572. package/src/array/last.ts +6 -14
  573. package/src/array/readme.md +3 -3
  574. package/src/assertion/assert_type.ts +1 -1
  575. package/src/bigint/is_bigint.ts +28 -21
  576. package/src/bigint/is_bigint_literal.ts +25 -17
  577. package/src/bigint/is_not_bigint.ts +27 -20
  578. package/src/bigint/is_not_bigint_literal.ts +26 -17
  579. package/src/bigint/readme.md +25 -8
  580. package/src/binary/_binary.ts +2 -1
  581. package/src/binary/bit.ts +29 -0
  582. package/src/binary/readme.md +11 -0
  583. package/src/boolean/is_boolean.ts +30 -23
  584. package/src/boolean/is_false.ts +18 -9
  585. package/src/boolean/is_not_boolean.ts +30 -22
  586. package/src/boolean/is_not_false.ts +19 -9
  587. package/src/boolean/is_not_true.ts +18 -9
  588. package/src/boolean/is_true.ts +18 -9
  589. package/src/equal/equal.ts +307 -89
  590. package/src/equal/identity_equal.ts +3 -7
  591. package/src/equal/is_equal.ts +150 -0
  592. package/src/equal/readme.md +20 -1
  593. package/src/function/is_function.ts +37 -5
  594. package/src/function/is_not_function.ts +1 -1
  595. package/src/function/is_not_strict_function.ts +16 -14
  596. package/src/function/is_strict_function.ts +29 -21
  597. package/src/functional/Maybe.ts +1 -1
  598. package/src/functional/compose.ts +1 -3
  599. package/src/index.ts +20 -21
  600. package/src/logical/logical.ts +52 -0
  601. package/src/logical/readme.md +53 -0
  602. package/src/math/abs.ts +1 -1
  603. package/src/mix_types/box.ts +2 -2
  604. package/src/mix_types/is_any_or_never.ts +2 -3
  605. package/src/mix_types/merge.ts +22 -17
  606. package/src/never/is_never.ts +16 -15
  607. package/src/never/is_not_never.ts +16 -15
  608. package/src/null/is_not_null.ts +18 -9
  609. package/src/null/is_null.ts +18 -9
  610. package/src/number/is_not_number.ts +27 -20
  611. package/src/number/is_not_number_literal.ts +25 -17
  612. package/src/number/is_number.ts +27 -20
  613. package/src/number/is_number_literal.ts +25 -17
  614. package/src/numeric/is_integer.ts +29 -30
  615. package/src/numeric/is_negative.ts +29 -20
  616. package/src/numeric/is_not_integer.ts +19 -10
  617. package/src/numeric/is_not_negative.ts +25 -13
  618. package/src/numeric/is_not_numeric.ts +1 -1
  619. package/src/numeric/is_not_positive.ts +19 -9
  620. package/src/numeric/is_numeric.ts +37 -5
  621. package/src/numeric/is_positive.ts +29 -21
  622. package/src/object/ANotB.ts +2 -2
  623. package/src/object/KeysWithDiffType.ts +1 -1
  624. package/src/object/adjust_exact_optional_props.ts +1 -1
  625. package/src/object/is_not_object.ts +29 -22
  626. package/src/object/is_object.ts +29 -22
  627. package/src/object/left_join.ts +2 -2
  628. package/src/object/mapProperties.ts +1 -1
  629. package/src/object/merge.ts +54 -50
  630. package/src/object/optional_key.ts +1 -1
  631. package/src/object/record.ts +1 -1
  632. package/src/object/split.ts +1 -1
  633. package/src/predicates/CanAssign.ts +1 -1
  634. package/src/predicates/assignable.ts +23 -25
  635. package/src/predicates/index.ts +1 -1
  636. package/src/predicates/not_assignable.ts +24 -26
  637. package/src/string/is_not_string.ts +29 -23
  638. package/src/string/is_not_string_literal.ts +36 -30
  639. package/src/string/is_not_template_literal.ts +24 -16
  640. package/src/string/is_string.ts +27 -20
  641. package/src/string/is_string_literal.ts +36 -30
  642. package/src/string/is_template_literal.ts +24 -16
  643. package/src/symbol/is_not_symbol.ts +18 -9
  644. package/src/symbol/is_symbol.ts +18 -9
  645. package/src/testing/stub.ts +0 -1
  646. package/src/testing/test_type.ts +1 -1
  647. package/src/tuple/is_not_tuple.ts +26 -17
  648. package/src/tuple/is_tuple.ts +25 -17
  649. package/src/tuple/tuple_plus.common_prop_keys.ts +1 -1
  650. package/src/tuple/tuple_plus.drop_match.ts +1 -1
  651. package/src/tuple/tuple_plus.find.ts +1 -1
  652. package/src/type-guard/is_type.ts +1 -1
  653. package/src/undefined/has_undefined.ts +5 -6
  654. package/src/undefined/is_not_undefined.ts +18 -9
  655. package/src/undefined/is_undefined.ts +18 -9
  656. package/src/unknown/is_not_unknown.ts +15 -14
  657. package/src/unknown/is_unknown.ts +15 -14
  658. package/src/unknown/not_unknown_or.ts +1 -1
  659. package/src/utils/Widen.ts +9 -2
  660. package/src/utils/excessive.ts +11 -0
  661. package/src/{type → utils}/no_infer.ts +13 -7
  662. package/src/utils/readme.md +17 -0
  663. package/src/void/is_not_void.ts +20 -10
  664. package/src/void/is_void.ts +20 -10
  665. package/cjs/any/any.d.ts +0 -49
  666. package/cjs/any/any.d.ts.map +0 -1
  667. package/cjs/any/any.js.map +0 -1
  668. package/cjs/binary/Bit.d.ts +0 -6
  669. package/cjs/binary/Bit.d.ts.map +0 -1
  670. package/cjs/binary/Bit.js.map +0 -1
  671. package/cjs/binary/index.d.ts +0 -3
  672. package/cjs/binary/index.d.ts.map +0 -1
  673. package/cjs/binary/index.js +0 -6
  674. package/cjs/binary/index.js.map +0 -1
  675. package/cjs/never/never.d.ts +0 -75
  676. package/cjs/never/never.d.ts.map +0 -1
  677. package/cjs/never/never.js.map +0 -1
  678. package/cjs/predicates/logical.d.ts +0 -5
  679. package/cjs/predicates/logical.d.ts.map +0 -1
  680. package/cjs/type/failed.d.ts.map +0 -1
  681. package/cjs/type/no_infer.d.ts.map +0 -1
  682. package/cjs/type_plus/$equality.d.ts +0 -12
  683. package/cjs/type_plus/$equality.d.ts.map +0 -1
  684. package/cjs/type_plus/$equality.js +0 -3
  685. package/cjs/type_plus/$equality.js.map +0 -1
  686. package/cjs/type_plus/$error.d.ts +0 -8
  687. package/cjs/type_plus/$error.d.ts.map +0 -1
  688. package/cjs/type_plus/$infer_error.d.ts.map +0 -1
  689. package/cjs/type_plus/$infer_error.js.map +0 -1
  690. package/cjs/type_plus/$merge_options.d.ts +0 -11
  691. package/cjs/type_plus/$merge_options.d.ts.map +0 -1
  692. package/cjs/type_plus/$merge_options.js.map +0 -1
  693. package/cjs/type_plus/$resolve_options.d.ts.map +0 -1
  694. package/cjs/type_plus/$resolve_options.js.map +0 -1
  695. package/cjs/type_plus/$special_type.d.ts +0 -19
  696. package/cjs/type_plus/$special_type.d.ts.map +0 -1
  697. package/cjs/type_plus/$special_type.js +0 -3
  698. package/cjs/type_plus/$special_type.js.map +0 -1
  699. package/cjs/type_plus/$type.d.ts +0 -11
  700. package/cjs/type_plus/$type.d.ts.map +0 -1
  701. package/cjs/type_plus/branch/$branch.d.ts.map +0 -1
  702. package/cjs/type_plus/branch/$branch.js.map +0 -1
  703. package/cjs/type_plus/branch/$distributive.d.ts +0 -19
  704. package/cjs/type_plus/branch/$distributive.d.ts.map +0 -1
  705. package/cjs/type_plus/branch/$distributive.js.map +0 -1
  706. package/cjs/type_plus/branch/$exact.d.ts +0 -21
  707. package/cjs/type_plus/branch/$exact.d.ts.map +0 -1
  708. package/cjs/type_plus/branch/$input_options.d.ts.map +0 -1
  709. package/cjs/type_plus/branch/$input_options.js.map +0 -1
  710. package/cjs/type_plus/branch/$is_distributive.d.ts +0 -6
  711. package/cjs/type_plus/branch/$is_distributive.d.ts.map +0 -1
  712. package/cjs/type_plus/branch/$is_distributive.js +0 -3
  713. package/cjs/type_plus/branch/$is_distributive.js.map +0 -1
  714. package/cjs/type_plus/branch/$override.d.ts +0 -21
  715. package/cjs/type_plus/branch/$override.d.ts.map +0 -1
  716. package/cjs/type_plus/branch/$override.js +0 -3
  717. package/cjs/type_plus/branch/$override.js.map +0 -1
  718. package/cjs/type_plus/branch/$resolve_branch.d.ts +0 -29
  719. package/cjs/type_plus/branch/$resolve_branch.d.ts.map +0 -1
  720. package/cjs/type_plus/branch/$resolve_branch.js.map +0 -1
  721. package/cjs/type_plus/branch/$select.d.ts +0 -77
  722. package/cjs/type_plus/branch/$select.d.ts.map +0 -1
  723. package/cjs/type_plus/branch/$select.js +0 -3
  724. package/cjs/type_plus/branch/$select.js.map +0 -1
  725. package/cjs/type_plus/branch/$select_invert.d.ts +0 -75
  726. package/cjs/type_plus/branch/$select_invert.d.ts.map +0 -1
  727. package/cjs/type_plus/branch/$select_invert.js +0 -3
  728. package/cjs/type_plus/branch/$select_invert.js.map +0 -1
  729. package/cjs/type_plus/branch/$select_invert_strict.d.ts +0 -75
  730. package/cjs/type_plus/branch/$select_invert_strict.d.ts.map +0 -1
  731. package/cjs/type_plus/branch/$select_invert_strict.js +0 -3
  732. package/cjs/type_plus/branch/$select_invert_strict.js.map +0 -1
  733. package/cjs/type_plus/branch/$select_strict.d.ts +0 -76
  734. package/cjs/type_plus/branch/$select_strict.d.ts.map +0 -1
  735. package/cjs/type_plus/branch/$select_strict.js +0 -3
  736. package/cjs/type_plus/branch/$select_strict.js.map +0 -1
  737. package/cjs/type_plus/branch/$selection.d.ts +0 -127
  738. package/cjs/type_plus/branch/$selection.d.ts.map +0 -1
  739. package/cjs/type_plus/branch/$selection.js.map +0 -1
  740. package/cjs/type_plus/branch/$selection_options.d.ts +0 -37
  741. package/cjs/type_plus/branch/$selection_options.d.ts.map +0 -1
  742. package/cjs/type_plus/branch/$selection_options.js +0 -3
  743. package/cjs/type_plus/branch/$selection_options.js.map +0 -1
  744. package/cjs/unknown/unknown.d.ts +0 -55
  745. package/cjs/unknown/unknown.d.ts.map +0 -1
  746. package/cjs/unknown/unknown.js +0 -3
  747. package/cjs/unknown/unknown.js.map +0 -1
  748. package/esm/any/any.d.ts +0 -49
  749. package/esm/any/any.d.ts.map +0 -1
  750. package/esm/any/any.js +0 -2
  751. package/esm/any/any.js.map +0 -1
  752. package/esm/binary/Bit.d.ts +0 -6
  753. package/esm/binary/Bit.d.ts.map +0 -1
  754. package/esm/binary/Bit.js +0 -2
  755. package/esm/binary/Bit.js.map +0 -1
  756. package/esm/binary/index.d.ts +0 -3
  757. package/esm/binary/index.d.ts.map +0 -1
  758. package/esm/binary/index.js +0 -3
  759. package/esm/binary/index.js.map +0 -1
  760. package/esm/never/never.d.ts +0 -75
  761. package/esm/never/never.d.ts.map +0 -1
  762. package/esm/never/never.js +0 -2
  763. package/esm/never/never.js.map +0 -1
  764. package/esm/predicates/logical.d.ts +0 -5
  765. package/esm/predicates/logical.d.ts.map +0 -1
  766. package/esm/type/failed.d.ts.map +0 -1
  767. package/esm/type/no_infer.d.ts.map +0 -1
  768. package/esm/type_plus/$equality.d.ts +0 -12
  769. package/esm/type_plus/$equality.d.ts.map +0 -1
  770. package/esm/type_plus/$equality.js +0 -2
  771. package/esm/type_plus/$equality.js.map +0 -1
  772. package/esm/type_plus/$error.d.ts +0 -8
  773. package/esm/type_plus/$error.d.ts.map +0 -1
  774. package/esm/type_plus/$infer_error.d.ts.map +0 -1
  775. package/esm/type_plus/$infer_error.js.map +0 -1
  776. package/esm/type_plus/$merge_options.d.ts +0 -11
  777. package/esm/type_plus/$merge_options.d.ts.map +0 -1
  778. package/esm/type_plus/$merge_options.js.map +0 -1
  779. package/esm/type_plus/$resolve_options.d.ts.map +0 -1
  780. package/esm/type_plus/$resolve_options.js.map +0 -1
  781. package/esm/type_plus/$special_type.d.ts +0 -19
  782. package/esm/type_plus/$special_type.d.ts.map +0 -1
  783. package/esm/type_plus/$special_type.js +0 -2
  784. package/esm/type_plus/$special_type.js.map +0 -1
  785. package/esm/type_plus/$type.d.ts +0 -11
  786. package/esm/type_plus/$type.d.ts.map +0 -1
  787. package/esm/type_plus/branch/$branch.d.ts.map +0 -1
  788. package/esm/type_plus/branch/$branch.js.map +0 -1
  789. package/esm/type_plus/branch/$distributive.d.ts +0 -19
  790. package/esm/type_plus/branch/$distributive.d.ts.map +0 -1
  791. package/esm/type_plus/branch/$distributive.js.map +0 -1
  792. package/esm/type_plus/branch/$exact.d.ts +0 -21
  793. package/esm/type_plus/branch/$exact.d.ts.map +0 -1
  794. package/esm/type_plus/branch/$input_options.d.ts.map +0 -1
  795. package/esm/type_plus/branch/$input_options.js.map +0 -1
  796. package/esm/type_plus/branch/$is_distributive.d.ts +0 -6
  797. package/esm/type_plus/branch/$is_distributive.d.ts.map +0 -1
  798. package/esm/type_plus/branch/$is_distributive.js +0 -2
  799. package/esm/type_plus/branch/$is_distributive.js.map +0 -1
  800. package/esm/type_plus/branch/$override.d.ts +0 -21
  801. package/esm/type_plus/branch/$override.d.ts.map +0 -1
  802. package/esm/type_plus/branch/$override.js +0 -2
  803. package/esm/type_plus/branch/$override.js.map +0 -1
  804. package/esm/type_plus/branch/$resolve_branch.d.ts +0 -29
  805. package/esm/type_plus/branch/$resolve_branch.d.ts.map +0 -1
  806. package/esm/type_plus/branch/$resolve_branch.js.map +0 -1
  807. package/esm/type_plus/branch/$select.d.ts +0 -77
  808. package/esm/type_plus/branch/$select.d.ts.map +0 -1
  809. package/esm/type_plus/branch/$select.js +0 -2
  810. package/esm/type_plus/branch/$select.js.map +0 -1
  811. package/esm/type_plus/branch/$select_invert.d.ts +0 -75
  812. package/esm/type_plus/branch/$select_invert.d.ts.map +0 -1
  813. package/esm/type_plus/branch/$select_invert.js +0 -2
  814. package/esm/type_plus/branch/$select_invert.js.map +0 -1
  815. package/esm/type_plus/branch/$select_invert_strict.d.ts +0 -75
  816. package/esm/type_plus/branch/$select_invert_strict.d.ts.map +0 -1
  817. package/esm/type_plus/branch/$select_invert_strict.js +0 -2
  818. package/esm/type_plus/branch/$select_invert_strict.js.map +0 -1
  819. package/esm/type_plus/branch/$select_strict.d.ts +0 -76
  820. package/esm/type_plus/branch/$select_strict.d.ts.map +0 -1
  821. package/esm/type_plus/branch/$select_strict.js +0 -2
  822. package/esm/type_plus/branch/$select_strict.js.map +0 -1
  823. package/esm/type_plus/branch/$selection.d.ts +0 -127
  824. package/esm/type_plus/branch/$selection.d.ts.map +0 -1
  825. package/esm/type_plus/branch/$selection.js.map +0 -1
  826. package/esm/type_plus/branch/$selection_options.d.ts +0 -37
  827. package/esm/type_plus/branch/$selection_options.d.ts.map +0 -1
  828. package/esm/type_plus/branch/$selection_options.js +0 -2
  829. package/esm/type_plus/branch/$selection_options.js.map +0 -1
  830. package/esm/unknown/unknown.d.ts +0 -55
  831. package/esm/unknown/unknown.d.ts.map +0 -1
  832. package/esm/unknown/unknown.js +0 -2
  833. package/esm/unknown/unknown.js.map +0 -1
  834. package/src/any/any.ts +0 -46
  835. package/src/binary/Bit.ts +0 -6
  836. package/src/binary/index.ts +0 -2
  837. package/src/never/never.ts +0 -78
  838. package/src/predicates/logical.ts +0 -19
  839. package/src/type/readme.md +0 -36
  840. package/src/type_plus/$equality.ts +0 -12
  841. package/src/type_plus/$error.ts +0 -8
  842. package/src/type_plus/$merge_options.ts +0 -8
  843. package/src/type_plus/$special_type.ts +0 -26
  844. package/src/type_plus/$type.ts +0 -10
  845. package/src/type_plus/branch/$distributive.ts +0 -19
  846. package/src/type_plus/branch/$exact.ts +0 -28
  847. package/src/type_plus/branch/$is_distributive.ts +0 -15
  848. package/src/type_plus/branch/$override.ts +0 -22
  849. package/src/type_plus/branch/$resolve_branch.ts +0 -71
  850. package/src/type_plus/branch/$select.ts +0 -89
  851. package/src/type_plus/branch/$select_invert.ts +0 -83
  852. package/src/type_plus/branch/$select_invert_strict.ts +0 -83
  853. package/src/type_plus/branch/$select_strict.ts +0 -88
  854. package/src/type_plus/branch/$selection.ts +0 -134
  855. package/src/type_plus/branch/$selection_options.ts +0 -36
  856. package/src/type_plus/readme.md +0 -25
  857. package/src/unknown/unknown.ts +0 -57
  858. /package/cjs/{type_plus → $type}/$resolve_options.js +0 -0
  859. /package/cjs/{type_plus → $type}/$type.js +0 -0
  860. /package/cjs/{type_plus → $type}/branch/$branch.js +0 -0
  861. /package/cjs/{type_plus → $type}/branch/$input_options.js +0 -0
  862. /package/cjs/{type_plus → $type}/branch/$resolve_branch.js +0 -0
  863. /package/cjs/{type_plus → $type}/branch/$selection.js +0 -0
  864. /package/cjs/{type_plus/branch → $type/distributive}/$distributive.js +0 -0
  865. /package/cjs/{type_plus → $type/errors}/$error.js +0 -0
  866. /package/cjs/{type_plus → $type/errors}/$infer_error.js +0 -0
  867. /package/cjs/{type → $type/errors}/failed.js +0 -0
  868. /package/cjs/{type_plus/branch → $type/exact}/$exact.js +0 -0
  869. /package/cjs/{type_plus → $type/utils}/$merge_options.js +0 -0
  870. /package/cjs/{predicates → logical}/logical.js +0 -0
  871. /package/cjs/{type → utils}/no_infer.js +0 -0
  872. /package/esm/{type_plus → $type}/$resolve_options.js +0 -0
  873. /package/esm/{type_plus → $type}/$type.js +0 -0
  874. /package/esm/{type_plus → $type}/branch/$branch.js +0 -0
  875. /package/esm/{type_plus → $type}/branch/$input_options.js +0 -0
  876. /package/esm/{type_plus → $type}/branch/$resolve_branch.js +0 -0
  877. /package/esm/{type_plus → $type}/branch/$selection.js +0 -0
  878. /package/esm/{type_plus/branch → $type/distributive}/$distributive.js +0 -0
  879. /package/esm/{type_plus → $type/errors}/$error.js +0 -0
  880. /package/esm/{type_plus → $type/errors}/$infer_error.js +0 -0
  881. /package/esm/{type → $type/errors}/failed.js +0 -0
  882. /package/esm/{type_plus/branch → $type/exact}/$exact.js +0 -0
  883. /package/esm/{type_plus → $type/utils}/$merge_options.js +0 -0
  884. /package/esm/{predicates → logical}/logical.js +0 -0
  885. /package/esm/{type → utils}/no_infer.js +0 -0
package/src/any/is_any.ts CHANGED
@@ -1,13 +1,13 @@
1
- import type { $Never } from '../never/never.js'
2
- import type { $SpecialType } from '../type_plus/$special_type.js'
3
- import type { $InputOptions } from '../type_plus/branch/$input_options.js'
4
- import type { $ResolveBranch } from '../type_plus/branch/$resolve_branch.js'
5
- import type { $Else, $SelectionBranch, $Then } from '../type_plus/branch/$selection.js'
6
- import type { $SelectionOptions } from '../type_plus/branch/$selection_options.js'
7
- import type { $Unknown } from '../unknown/unknown.js'
1
+ import type { $InputOptions } from '../$type/branch/$input_options.js'
2
+ import type { $ResolveBranch } from '../$type/branch/$resolve_branch.js'
3
+ import type { $Else, $Selection, $Then } from '../$type/branch/$selection.js'
4
+ import type { $Never } from '../$type/special/$never.js'
5
+ import type { $Special } from '../$type/special/$special.js'
6
+ import type { $Unknown } from '../$type/special/$unknown.js'
7
+ import type { $Void } from '../$type/special/$void.js'
8
8
 
9
9
  /**
10
- * 🎭 *predicate*
10
+ * 🎭 **predicate**
11
11
  *
12
12
  * Validate if `T` is `any`.
13
13
  *
@@ -20,40 +20,43 @@ import type { $Unknown } from '../unknown/unknown.js'
20
20
  * type R = IsAny<string | boolean> // false
21
21
  * ```
22
22
  *
23
- * 🔢 *customize*
23
+ * 🌪️ **filter**
24
24
  *
25
25
  * Filter to ensure `T` is `any`.
26
26
  *
27
27
  * @example
28
28
  * ```ts
29
29
  * type R = IsAny<any, { selection: 'filter' }> // any
30
- *
31
30
  * type R = IsAny<never, { selection: 'filter' }> // never
32
31
  * type R = IsAny<unknown, { selection: 'filter' }> // never
33
32
  * type R = IsAny<string | boolean, { selection: 'filter' }> // never
34
33
  * ```
35
34
  *
36
- * 🔢 *customize*
35
+ * 🔱 **branching**
37
36
  *
38
37
  * Use unique branch identifiers to allow precise processing of the result.
39
38
  *
40
39
  * @example
41
40
  * ```ts
42
- * type R = IsAny<any, $SelectionBranch> // $Then
43
- * type R = IsAny<string, $SelectionBranch> // $Else
41
+ * type R = IsAny<any, $Selection.Branch> // $Then
42
+ * type R = IsAny<string, $Selection.Branch> // $Else
43
+ * type R = IsAny<unknown, IsAny.$Branch> // $Unknown
44
+ * type R = IsAny<never, IsAny.$Branch> // $Never
45
+ * type R = IsAny<void, IsAny.$Branch> // $Void
44
46
  * ```
45
47
  */
46
- export type IsAny<T, $O extends IsAny.$Options = {}> = $SpecialType<
48
+ export type IsAny<T, $O extends IsAny.$Options = {}> = $Special<
47
49
  T,
48
50
  {
49
- $any: $ResolveBranch<T, $O, [$Then]>
50
- $unknown: $ResolveBranch<T, $O, [$Unknown, $Else]>
51
- $never: $ResolveBranch<T, $O, [$Never, $Else]>
52
- $else: $ResolveBranch<T, $O, [$Else]>
51
+ $any: $ResolveBranch<$O, [$Then], T>
52
+ $unknown: $ResolveBranch<$O, [$Unknown, $Else]>
53
+ $never: $ResolveBranch<$O, [$Never, $Else]>
54
+ $void: $ResolveBranch<$O, [$Void, $Else]>
55
+ $else: $ResolveBranch<$O, [$Else]>
53
56
  }
54
57
  >
55
58
 
56
59
  export namespace IsAny {
57
- export type $Options = $SelectionOptions & $InputOptions<$Unknown | $Never>
58
- export type $Branch = $SelectionBranch
60
+ export type $Options = $Selection.Options & $InputOptions<$Unknown | $Never | $Void>
61
+ export type $Branch = $Selection.Branch & $Unknown.$Branch & $Never.$Branch & $Void.$Branch
59
62
  }
@@ -1,10 +1,10 @@
1
- import type { $Never } from '../never/never.js'
2
- import type { $SpecialType } from '../type_plus/$special_type.js'
3
- import type { $InputOptions } from '../type_plus/branch/$input_options.js'
4
- import type { $ResolveBranch } from '../type_plus/branch/$resolve_branch.js'
5
- import type { $Else, $SelectionBranch, $Then } from '../type_plus/branch/$selection.js'
6
- import type { $SelectionOptions } from '../type_plus/branch/$selection_options.js'
7
- import type { $Unknown } from '../unknown/unknown.js'
1
+ import type { $InputOptions } from '../$type/branch/$input_options.js'
2
+ import type { $ResolveBranch } from '../$type/branch/$resolve_branch.js'
3
+ import type { $Else, $Selection, $Then } from '../$type/branch/$selection.js'
4
+ import type { $Never } from '../$type/special/$never.js'
5
+ import type { $Special } from '../$type/special/$special.js'
6
+ import type { $Unknown } from '../$type/special/$unknown.js'
7
+ import type { $Void } from '../$type/special/$void.js'
8
8
 
9
9
  /**
10
10
  * 🎭 *predicate*
@@ -43,17 +43,18 @@ import type { $Unknown } from '../unknown/unknown.js'
43
43
  * type R = IsNotAny<string, $SelectionBranch> // $Then
44
44
  * ```
45
45
  */
46
- export type IsNotAny<T, $O extends IsNotAny.$Options = {}> = $SpecialType<
46
+ export type IsNotAny<T, $O extends IsNotAny.$Options = {}> = $Special<
47
47
  T,
48
48
  {
49
- $any: $ResolveBranch<T, $O, [$Else]>
50
- $unknown: $ResolveBranch<T, $O, [$Unknown, $Then]>
51
- $never: $ResolveBranch<T, $O, [$Never, $Then]>
52
- $else: $ResolveBranch<T, $O, [$Then]>
49
+ $any: $ResolveBranch<$O, [$Else]>
50
+ $never: $ResolveBranch<$O, [$Never, $Then], T>
51
+ $unknown: $ResolveBranch<$O, [$Unknown, $Then], T>
52
+ $void: $ResolveBranch<$O, [$Void, $Then], T>
53
+ $else: $ResolveBranch<$O, [$Then], T>
53
54
  }
54
55
  >
55
56
 
56
57
  export namespace IsNotAny {
57
- export type $Options = $SelectionOptions & $InputOptions<$Unknown | $Never>
58
- export type $Branch = $SelectionBranch
58
+ export type $Options = $Selection.Options & $InputOptions<$Unknown | $Never | $Void>
59
+ export type $Branch = $Selection.Branch & $Unknown.$Branch & $Never.$Branch & $Void.$Branch
59
60
  }
package/src/any/readme.md CHANGED
@@ -1,16 +1,25 @@
1
- # Any
1
+ # `any`
2
2
 
3
- `any` is one of the two top types in TypeScript.
4
- It is a supertype of all types.
3
+ The `any` type is one of the two top types in TypeScript.
4
+ It is a super-type of all types.
5
5
  It is a way to opt-out of type checking and let the values pass through compile-time checks.
6
6
 
7
- ## [IsAny](./is_any.ts)
7
+ ## [`IsAny`](./is_any.ts)
8
8
 
9
- `IsAny<T, $O = { selection: 'predicate' | 'filter', $then: true, $else: false }>`
9
+ ```ts
10
+ IsAny<T, $O = {
11
+ selection: 'predicate' | 'filter' = 'predicate',
12
+ $then: unknown = true,
13
+ $else: unknown = false,
14
+ $unknown: unknown,
15
+ $never: unknown,
16
+ $void: unknown
17
+ }>
18
+ ```
10
19
 
11
- 🎭 *predicate*
20
+ 🎭 **predicate**
12
21
 
13
- Validate if `T` is exactly `any`.
22
+ Validate if `T` is `any`.
14
23
 
15
24
  ```ts
16
25
  type R = IsAny<any> // true
@@ -20,32 +29,34 @@ type R = IsAny<unknown> // false
20
29
  type R = IsAny<string | boolean> // false
21
30
  ```
22
31
 
23
- 🔢 *customize*
32
+ 🌪️ **filter**
24
33
 
25
- Filter to ensure `T` is exactly `any`.
34
+ Filter to ensure `T` is `any`.
26
35
 
27
36
  ```ts
28
37
  type R = IsAny<any, { selection: 'filter' }> // any
29
-
30
38
  type R = IsAny<never, { selection: 'filter' }> // never
31
39
  type R = IsAny<unknown, { selection: 'filter' }> // never
32
40
  type R = IsAny<string | boolean, { selection: 'filter' }> // never
33
41
  ```
34
42
 
35
- 🔢 *customize*
43
+ 🔱 **branching**
36
44
 
37
45
  Use unique branch identifiers to allow precise processing of the result.
38
46
 
39
47
  ```ts
40
- type R = IsAny<any, $SelectionBranch> // $Then
41
- type R = IsAny<string, $SelectionBranch> // $Else
48
+ type R = IsAny<any, $Selection.Branch> // $Then
49
+ type R = IsAny<string, $Selection.Branch> // $Else
50
+ type R = IsAny<unknown, IsAny.$Branch> // $Unknown
51
+ type R = IsAny<never, IsAny.$Branch> // $Never
52
+ type R = IsAny<void, IsAny.$Branch> // $Void
42
53
  ```
43
54
 
44
- ### [IsNotAny](./is_not_any.ts)
55
+ ### [`IsNotAny`](./is_not_any.ts)
45
56
 
46
57
  `IsNotAny<T, $O = { selection: 'predicate' | 'filter', $then: true, $else: false }>`
47
58
 
48
- 🎭 *predicate*
59
+ 🎭 **predicate**
49
60
 
50
61
  Validate if `T` is not exactly `any`.
51
62
 
@@ -57,7 +68,7 @@ type R = IsNotAny<unknown> // true
57
68
  type R = IsNotAny<string | boolean> // true
58
69
  ```
59
70
 
60
- 🔢 *customize*
71
+ 🌪️ **filter**
61
72
 
62
73
  Filter to ensure `T` is not exactly `any`.
63
74
 
@@ -69,7 +80,7 @@ type R = IsNotAny<unknown, { selection: 'filter' }> // unknown
69
80
  type R = IsNotAny<string | boolean, { selection: 'filter' }> // string | boolean
70
81
  ```
71
82
 
72
- 🔢 *customize*
83
+ 🔱 **branching**
73
84
 
74
85
  Use unique branch identifiers to allow precise processing of the result.
75
86
 
@@ -85,8 +96,8 @@ type R = IsNotAny<string, $SelectionBranch> // $Then
85
96
  Well, yeah:
86
97
 
87
98
  ```ts
88
- type A = any extends unknown ? 1 : 2 // 1
89
- type B = unknown extends any ? 1 : 2 // 1
99
+ type A = any extends unknown ? true : false // true
100
+ type B = unknown extends any ? true : false // true
90
101
  ```
91
102
 
92
103
  > Aren't using `any` is bad?
@@ -1,4 +1,4 @@
1
- import type { IsEqual } from '../equal/equal.js'
1
+ import type { IsEqual } from '../equal/is_equal.js'
2
2
  import type { CanAssign } from '../index.js'
3
3
  import type { Tail } from '../tuple/tail.js'
4
4
  import type { UnionOfValues } from './union_of_values.js'
@@ -1,5 +1,5 @@
1
+ import type { $Never } from '../$type/special/$never.js'
1
2
  import type { IsNever } from '../never/is_never.js'
2
- import type { $Never } from '../never/never.js'
3
3
  import type { KeyTypes } from '../object/KeyTypes.js'
4
4
 
5
5
  /**
@@ -5,9 +5,9 @@
5
5
  // */
6
6
  // export type Filter<A extends readonly unknown[], Criteria = true> = Filter._<A, Criteria, []>
7
7
 
8
- import type { IsEqual } from '../equal/equal.js'
8
+ import type { $Never } from '../$type/special/$never.js'
9
+ import type { IsEqual } from '../equal/is_equal.js'
9
10
  import type { IsNever } from '../never/is_never.js'
10
- import type { $Never } from '../never/never.js'
11
11
  import type { TypePlusOptions } from '../utils/options.js'
12
12
 
13
13
  /**
@@ -1,6 +1,6 @@
1
- import type { $Never } from '../never/never.js'
1
+ import type { $ResolveOptions } from '../$type/$resolve_options.js'
2
+ import type { $Never } from '../$type/special/$never.js'
2
3
  import type { IsTuple } from '../tuple/is_tuple.js'
3
- import type { $ResolveOptions } from '../type_plus/$resolve_options.js'
4
4
  import type { ElementMatch } from './array_plus.element_match.js'
5
5
 
6
6
  /**
@@ -1,5 +1,5 @@
1
1
  import type { IsAny } from '../any/is_any.js'
2
- import type { IsEqual } from '../equal/equal.js'
2
+ import type { IsEqual } from '../equal/is_equal.js'
3
3
  import type { Abs } from '../math/abs.js'
4
4
  import type { GreaterThan } from '../math/greater_than.js'
5
5
  import type { Subtract } from '../math/subtract.js'
@@ -7,7 +7,6 @@ import type { IsNever } from '../never/is_never.js'
7
7
  import type { IsNumber } from '../number/is_number.js'
8
8
  import type { IsInteger } from '../numeric/is_integer.js'
9
9
  import type { IsNegative } from '../numeric/is_negative.js'
10
- import type { $Else, $SelectionBranch, $Then } from '../type_plus/branch/$selection.js'
11
10
 
12
11
  /**
13
12
  * 🦴 *utilities*
@@ -29,13 +28,13 @@ export type IndexAt<
29
28
  Fail = never,
30
29
  Upper = A['length'],
31
30
  Lower = 0,
32
- > = IsNever<A, $SelectionBranch> extends infer R
33
- ? R extends $Then
34
- ? Fail
35
- : R extends $Else
36
- ? IndexAt._<A, N, Fail, Upper, Lower>
37
- : never
38
- : never
31
+ > = IsNever<
32
+ A,
33
+ {
34
+ $then: Fail
35
+ $else: IndexAt._<A, N, Fail, Upper, Lower>
36
+ }
37
+ >
39
38
 
40
39
  export namespace IndexAt {
41
40
  export type _<A extends readonly unknown[], N extends number, Fail = never, Upper = A['length'], Lower = 0> = IsEqual<
@@ -45,31 +44,26 @@ export namespace IndexAt {
45
44
  IsInteger<
46
45
  N,
47
46
  {
48
- $then: IsNumber<A['length'], IsNumber.$Branch<{ exact: true }>> extends infer R
49
- ? // A: array
50
- R extends $Then
51
- ? N
52
- : // A: tuple
53
- R extends $Else
54
- ? IsNegative<
55
- N,
56
- {
57
- $then: GreaterThan<Abs<N>, A['length']> extends true ? Lower : Subtract<A['length'], Abs<N>>
58
- $else: GreaterThan<A['length'], N> extends true ? N : Upper
59
- }
60
- >
61
- : never
62
- : never
47
+ $then: IsNumber<
48
+ A['length'],
49
+ {
50
+ exact: true
51
+ $then: N
52
+ $else: IsNegative<
53
+ N,
54
+ {
55
+ $then: GreaterThan<Abs<N>, A['length']> extends true ? Lower : Subtract<A['length'], Abs<N>>
56
+ $else: GreaterThan<A['length'], N> extends true ? N : Upper
57
+ }
58
+ >
59
+ }
60
+ >
63
61
  // N: number or float
64
62
  $else: IsAny<
65
63
  N,
66
64
  {
67
65
  $then: number
68
- $else: IsNumber<N, IsNumber.$Branch<{ exact: true }>> extends infer R
69
- ? R extends $Then
70
- ? N
71
- : never
72
- : never
66
+ $else: IsNumber<N, { exact: true; $then: N; $else: never }>
73
67
  }
74
68
  >
75
69
  }
@@ -1,6 +1,6 @@
1
+ import type { $Selection } from '../$type/branch/$selection.js'
2
+ import type { $Never } from '../$type/special/$never.js'
1
3
  import type { IsNever } from '../never/is_never.js'
2
- import type { $Never } from '../never/never.js'
3
- import type { $SelectionOptions } from '../type_plus/branch/$selection_options.js'
4
4
  import type { TypePlusOptions } from '../utils/options.js'
5
5
  import type { LooseArrayType } from './loose_array_type.js'
6
6
 
@@ -35,7 +35,7 @@ export type IsReadonly<A, $Options extends IsReadonly.Options = IsReadonly.Defau
35
35
  : never
36
36
 
37
37
  export namespace IsReadonly {
38
- export interface Options extends $Never.$Options, $SelectionOptions, TypePlusOptions.NotArray {}
38
+ export interface Options extends $Never.$Options, $Selection.Options, TypePlusOptions.NotArray {}
39
39
 
40
40
  export interface DefaultOptions {
41
41
  $then: true
package/src/array/head.ts CHANGED
@@ -1,6 +1,6 @@
1
+ import type { $Else, $Selection, $Then } from '../$type/branch/$selection.js'
2
+ import type { $Never } from '../$type/special/$never.js'
1
3
  import type { IsNever } from '../never/is_never.js'
2
- import type { $Never } from '../never/never.js'
3
- import type { $Else, $SelectionBranch, $Then } from '../type_plus/branch/$selection.js'
4
4
 
5
5
  /**
6
6
  * 🦴 *utilities*
@@ -24,7 +24,7 @@ import type { $Else, $SelectionBranch, $Then } from '../type_plus/branch/$select
24
24
  */
25
25
  export type Head<T extends readonly unknown[], Options extends Head.Options = Head.DefaultOptions> = IsNever<
26
26
  T,
27
- $SelectionBranch
27
+ $Selection.Branch
28
28
  > extends infer R
29
29
  ? R extends $Then
30
30
  ? Options['$never']
@@ -1,11 +1,15 @@
1
+ import type { $InputOptions } from '../$type/branch/$input_options.js'
2
+ import type { $ResolveBranch } from '../$type/branch/$resolve_branch.js'
3
+ import type { $Else, $Selection, $Then } from '../$type/branch/$selection.js'
4
+ import type { $Distributive } from '../$type/distributive/$distributive.js'
5
+ import type { $Exact } from '../$type/exact/$exact.js'
6
+ import type { $Any } from '../$type/special/$any.js'
7
+ import type { $Never } from '../$type/special/$never.js'
8
+ import type { $Special } from '../$type/special/$special.js'
9
+ import type { $Unknown } from '../$type/special/$unknown.js'
10
+ import type { $Void } from '../$type/special/$void.js'
11
+ import type { $MergeOptions } from '../$type/utils/$merge_options.js'
1
12
  import type { Assignable } from '../predicates/assignable.js'
2
- import type { $Equality } from '../type_plus/$equality.js'
3
- import type { $MergeOptions } from '../type_plus/$merge_options.js'
4
- import type { $SpecialType } from '../type_plus/$special_type.js'
5
- import type { $ExactOptions, $IsExact } from '../type_plus/branch/$exact.js'
6
- import type { $IsDistributive } from '../type_plus/branch/$is_distributive.js'
7
- import type { $ResolveBranch } from '../type_plus/branch/$resolve_branch.js'
8
- import type { $Else, $Then } from '../type_plus/branch/$selection.js'
9
13
 
10
14
  /**
11
15
  * 🎭 *predicate*
@@ -60,20 +64,23 @@ import type { $Else, $Then } from '../type_plus/branch/$selection.js'
60
64
  * type R = IsArray<number, IsArray.$Branch> // $Else
61
65
  * ```
62
66
  */
63
- export type IsArray<T, $O extends IsArray.$Options = {}> = $SpecialType<
67
+ export type IsArray<T, $O extends IsArray.$Options = {}> = $Special<
64
68
  T,
65
69
  $MergeOptions<
66
70
  $O,
67
71
  {
68
- $then: $ResolveBranch<T, $O, [$Else]>
72
+ $then: $ResolveBranch<$O, [$Else]>
69
73
  $else: IsArray.$<T, $O>
70
74
  }
71
75
  >
72
76
  >
73
77
 
74
78
  export namespace IsArray {
75
- export type $Options = $Equality.$Options & $ExactOptions
76
- export type $Branch<$O extends $Options = {}> = $Equality.$Branch<$O>
79
+ export type $Options = $Selection.Options &
80
+ $Distributive.Options &
81
+ $Exact.Options &
82
+ $InputOptions<$Any | $Unknown | $Never | $Void>
83
+ export type $Branch<$O extends $Options = {}> = $Selection.Branch<$O>
77
84
 
78
85
  /**
79
86
  * 🧰 *type util*
@@ -83,33 +90,33 @@ export namespace IsArray {
83
90
  * This is a type util for building custom types.
84
91
  * It does not check against special types.
85
92
  */
86
- export type $<T, $O extends $UtilOptions> = $IsExact<
93
+ export type $<T, $O extends $UtilOptions> = $Exact.Parse<
87
94
  $O,
88
95
  {
89
- $then: $IsDistributive<
96
+ $then: $Distributive.Parse<
90
97
  $O,
91
98
  {
92
99
  $then: T extends readonly any[]
93
100
  ? number extends T['length']
94
- ? $ResolveBranch<T, $O, [$Then]>
95
- : $ResolveBranch<T, $O, [$Else]>
96
- : $ResolveBranch<T, $O, [$Else]>
101
+ ? $ResolveBranch<$O, [$Then], T>
102
+ : $ResolveBranch<$O, [$Else]>
103
+ : $ResolveBranch<$O, [$Else]>
97
104
  $else: [T] extends [readonly any[]]
98
105
  ? number extends T['length']
99
- ? $ResolveBranch<T, $O, [$Then]>
100
- : $ResolveBranch<T, $O, [$Else]>
101
- : $ResolveBranch<T, $O, [$Else]>
106
+ ? $ResolveBranch<$O, [$Then], T>
107
+ : $ResolveBranch<$O, [$Else]>
108
+ : $ResolveBranch<$O, [$Else]>
102
109
  }
103
110
  >
104
- $else: $IsDistributive<
111
+ $else: $Distributive.Parse<
105
112
  $O,
106
113
  {
107
- $then: T extends readonly any[] ? $ResolveBranch<T, $O, [$Then]> : $ResolveBranch<T, $O, [$Else]>
108
- $else: [T] extends readonly [any[]] ? $ResolveBranch<T, $O, [$Then]> : $ResolveBranch<T, $O, [$Else]>
114
+ $then: T extends readonly any[] ? $ResolveBranch<$O, [$Then], T> : $ResolveBranch<$O, [$Else]>
115
+ $else: [T] extends readonly [any[]] ? $ResolveBranch<$O, [$Then], T> : $ResolveBranch<$O, [$Else]>
109
116
  }
110
117
  >
111
118
  }
112
119
  >
113
120
 
114
- export type $UtilOptions = Assignable.$UtilOptions & $ExactOptions
121
+ export type $UtilOptions = Assignable.$UtilOptions & $Exact.Options
115
122
  }
@@ -1,11 +1,15 @@
1
+ import type { $InputOptions } from '../$type/branch/$input_options.js'
2
+ import type { $ResolveBranch } from '../$type/branch/$resolve_branch.js'
3
+ import type { $Else, $Selection, $Then } from '../$type/branch/$selection.js'
4
+ import type { $Distributive } from '../$type/distributive/$distributive.js'
5
+ import type { $Exact } from '../$type/exact/$exact.js'
6
+ import type { $Any } from '../$type/special/$any.js'
7
+ import type { $Never } from '../$type/special/$never.js'
8
+ import type { $Special } from '../$type/special/$special.js'
9
+ import type { $Unknown } from '../$type/special/$unknown.js'
10
+ import type { $Void } from '../$type/special/$void.js'
11
+ import type { $MergeOptions } from '../$type/utils/$merge_options.js'
1
12
  import type { NotAssignable } from '../predicates/not_assignable.js'
2
- import type { $Equality } from '../type_plus/$equality.js'
3
- import type { $MergeOptions } from '../type_plus/$merge_options.js'
4
- import type { $SpecialType } from '../type_plus/$special_type.js'
5
- import type { $ExactOptions, $IsExact } from '../type_plus/branch/$exact.js'
6
- import type { $IsDistributive } from '../type_plus/branch/$is_distributive.js'
7
- import type { $ResolveBranch } from '../type_plus/branch/$resolve_branch.js'
8
- import type { $Else, $Then } from '../type_plus/branch/$selection.js'
9
13
 
10
14
  /**
11
15
  * 🎭 *predicate*
@@ -60,19 +64,22 @@ import type { $Else, $Then } from '../type_plus/branch/$selection.js'
60
64
  * type R = IsNotArray<number, IsNotArray.$Branch> // $Then
61
65
  * ```
62
66
  */
63
- export type IsNotArray<T, $O extends IsNotArray.$Options = {}> = $SpecialType<
67
+ export type IsNotArray<T, $O extends IsNotArray.$Options = {}> = $Special<
64
68
  T,
65
69
  $MergeOptions<
66
70
  $O,
67
71
  {
68
- $then: $ResolveBranch<T, $O, [$Then]>
72
+ $then: $ResolveBranch<$O, [$Then], T>
69
73
  $else: IsNotArray.$<T, $O>
70
74
  }
71
75
  >
72
76
  >
73
77
  export namespace IsNotArray {
74
- export type $Options = $Equality.$Options & $ExactOptions
75
- export type $Branch<$O extends $Options = {}> = $Equality.$Branch<$O>
78
+ export type $Options = $Selection.Options &
79
+ $Distributive.Options &
80
+ $Exact.Options &
81
+ $InputOptions<$Any | $Unknown | $Never | $Void>
82
+ export type $Branch<$O extends $Options = {}> = $Selection.Branch<$O>
76
83
 
77
84
  /**
78
85
  * 🧰 *type util*
@@ -82,33 +89,33 @@ export namespace IsNotArray {
82
89
  * This is a type util for building custom types.
83
90
  * It does not check against special types.
84
91
  */
85
- export type $<T, $O extends $UtilOptions> = $IsExact<
92
+ export type $<T, $O extends $UtilOptions> = $Exact.Parse<
86
93
  $O,
87
94
  {
88
- $then: $IsDistributive<
95
+ $then: $Distributive.Parse<
89
96
  $O,
90
97
  {
91
98
  $then: T extends readonly any[]
92
99
  ? number extends T['length']
93
- ? $ResolveBranch<T, $O, [$Else]>
94
- : $ResolveBranch<T, $O, [$Then]>
95
- : $ResolveBranch<T, $O, [$Then]>
100
+ ? $ResolveBranch<$O, [$Else]>
101
+ : $ResolveBranch<$O, [$Then], T>
102
+ : $ResolveBranch<$O, [$Then], T>
96
103
  $else: [T] extends [readonly any[]]
97
104
  ? number extends T['length']
98
- ? $ResolveBranch<T, $O, [$Else]>
99
- : $ResolveBranch<T, $O, [$Then]>
100
- : $ResolveBranch<T, $O, [$Then]>
105
+ ? $ResolveBranch<$O, [$Else]>
106
+ : $ResolveBranch<$O, [$Then], T>
107
+ : $ResolveBranch<$O, [$Then], T>
101
108
  }
102
109
  >
103
- $else: $IsDistributive<
110
+ $else: $Distributive.Parse<
104
111
  $O,
105
112
  {
106
- $then: T extends readonly any[] ? $ResolveBranch<T, $O, [$Else]> : $ResolveBranch<T, $O, [$Then]>
107
- $else: [T] extends readonly [any[]] ? $ResolveBranch<T, $O, [$Else]> : $ResolveBranch<T, $O, [$Then]>
113
+ $then: T extends readonly any[] ? $ResolveBranch<$O, [$Else]> : $ResolveBranch<$O, [$Then], T>
114
+ $else: [T] extends readonly [any[]] ? $ResolveBranch<$O, [$Else]> : $ResolveBranch<$O, [$Then], T>
108
115
  }
109
116
  >
110
117
  }
111
118
  >
112
119
 
113
- export type $UtilOptions = NotAssignable.$UtilOptions & $ExactOptions
120
+ export type $UtilOptions = NotAssignable.$UtilOptions & $Exact.Options
114
121
  }
package/src/array/last.ts CHANGED
@@ -1,6 +1,5 @@
1
+ import type { $Never } from '../$type/special/$never.js'
1
2
  import type { IsNever } from '../never/is_never.js'
2
- import type { $Never } from '../never/never.js'
3
- import type { $Else, $SelectionBranch, $Then } from '../type_plus/branch/$selection.js'
4
3
 
5
4
  /**
6
5
  * 🦴 *utilities*
@@ -23,18 +22,11 @@ import type { $Else, $SelectionBranch, $Then } from '../type_plus/branch/$select
23
22
  */
24
23
  export type Last<T extends readonly unknown[], Options extends Last.Options = Last.DefaultOptions> = IsNever<
25
24
  T,
26
- $SelectionBranch
27
- > extends infer R
28
- ? R extends $Then
29
- ? Options['$never']
30
- : R extends $Else
31
- ? T['length'] extends 0
32
- ? Options['caseEmptyTuple']
33
- : T extends readonly [...unknown[], infer R]
34
- ? R
35
- : T[0]
36
- : never
37
- : never
25
+ {
26
+ $then: Options['$never']
27
+ $else: T['length'] extends 0 ? Options['caseEmptyTuple'] : T extends readonly [...unknown[], infer R] ? R : T[0]
28
+ }
29
+ >
38
30
 
39
31
  export namespace Last {
40
32
  export interface Options extends $Never.$Options {
@@ -1,10 +1,10 @@
1
1
  # Array
2
2
 
3
- In TypeScript, the type of an JavaScript array can be an [array](#array) or a [tuple](../tuple/readme.md).
3
+ In TypeScript, the type of JavaScript array can be an [array](#array) or a [tuple](../tuple/readme.md).
4
4
 
5
5
  `Array<T>` or `T[]` is a type that represents an array of `T`
6
6
 
7
- There is no length limitation to an `Array`,
7
+ There is no length limitation to a `Array`,
8
8
  and each element has the same type `T`.
9
9
 
10
10
  ## Type Checking
@@ -14,7 +14,7 @@ The `ArrayType<T>` and friends are used to check if a type is exactly `Array<T>`
14
14
  They are strict type checks, meaning they match only the type `Array<T>`,
15
15
  and not [tuple], [union], or intersection types.
16
16
 
17
- ### [ArrayType](./array_type.ts#l18)
17
+ ### [`ArrayType`](./array_type.ts#l18)
18
18
 
19
19
  `ArrayType<T, Then = T, Else = never>`
20
20
 
@@ -1,5 +1,5 @@
1
1
  import { tersify } from 'tersify'
2
- import { isConstructor, type AnyConstructor } from '../class/index.js'
2
+ import { type AnyConstructor, isConstructor } from '../class/index.js'
3
3
  import type { AnyFunction } from '../function/any_function.js'
4
4
 
5
5
  /**