@vinicunca/perkakas 1.15.0 → 1.16.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 (563) hide show
  1. package/dist/add-prop.cjs +1 -1
  2. package/dist/add-prop.cjs.map +1 -1
  3. package/dist/add-prop.js.map +1 -1
  4. package/dist/add.cjs +1 -1
  5. package/dist/add.cjs.map +1 -1
  6. package/dist/add.js.map +1 -1
  7. package/dist/all-pass.cjs +1 -1
  8. package/dist/all-pass.cjs.map +1 -1
  9. package/dist/all-pass.js.map +1 -1
  10. package/dist/any-pass.cjs +1 -1
  11. package/dist/any-pass.cjs.map +1 -1
  12. package/dist/any-pass.js.map +1 -1
  13. package/dist/{binary-search-cutoff-index-TJlnoie4.js → binary-search-cutoff-index-CRPy-dOJ.js} +1 -1
  14. package/dist/{binary-search-cutoff-index-TJlnoie4.js.map → binary-search-cutoff-index-CRPy-dOJ.js.map} +1 -1
  15. package/dist/binary-search-cutoff-index-CdUUMUB1.cjs +2 -0
  16. package/dist/{binary-search-cutoff-index-CLFtXYPc.cjs.map → binary-search-cutoff-index-CdUUMUB1.cjs.map} +1 -1
  17. package/dist/capitalize.cjs +1 -1
  18. package/dist/capitalize.cjs.map +1 -1
  19. package/dist/capitalize.js.map +1 -1
  20. package/dist/ceil.cjs +1 -1
  21. package/dist/ceil.cjs.map +1 -1
  22. package/dist/ceil.js +1 -1
  23. package/dist/ceil.js.map +1 -1
  24. package/dist/chunk.cjs +1 -1
  25. package/dist/chunk.cjs.map +1 -1
  26. package/dist/chunk.js.map +1 -1
  27. package/dist/clamp.cjs +1 -1
  28. package/dist/clamp.cjs.map +1 -1
  29. package/dist/clamp.js.map +1 -1
  30. package/dist/clone.cjs +1 -1
  31. package/dist/clone.cjs.map +1 -1
  32. package/dist/clone.js.map +1 -1
  33. package/dist/concat.cjs +1 -1
  34. package/dist/concat.cjs.map +1 -1
  35. package/dist/concat.js.map +1 -1
  36. package/dist/conditional.cjs +2 -1
  37. package/dist/conditional.cjs.map +1 -0
  38. package/dist/conditional.js +2 -1
  39. package/dist/conditional.js.map +1 -0
  40. package/dist/constant.cjs.map +1 -1
  41. package/dist/constant.js.map +1 -1
  42. package/dist/count-by.cjs +1 -1
  43. package/dist/count-by.cjs.map +1 -1
  44. package/dist/count-by.js.map +1 -1
  45. package/dist/{curry-from-lazy-CtH1dp14.js → curry-from-lazy-BoPMn2L_.js} +1 -1
  46. package/dist/{curry-from-lazy-CtH1dp14.js.map → curry-from-lazy-BoPMn2L_.js.map} +1 -1
  47. package/dist/{curry-from-lazy-BvN_VKlH.cjs → curry-from-lazy-mdjeRP1g.cjs} +2 -2
  48. package/dist/{curry-from-lazy-BvN_VKlH.cjs.map → curry-from-lazy-mdjeRP1g.cjs.map} +1 -1
  49. package/dist/curry-on-Et2NUOHd.js +2 -0
  50. package/dist/curry-on-Et2NUOHd.js.map +1 -0
  51. package/dist/curry-on-wBH_q-mO.cjs +2 -0
  52. package/dist/curry-on-wBH_q-mO.cjs.map +1 -0
  53. package/dist/{curry-order-rules-DsJSy3gX.cjs → curry-order-rules-CacOTzfW.cjs} +2 -2
  54. package/dist/{curry-order-rules-DsJSy3gX.cjs.map → curry-order-rules-CacOTzfW.cjs.map} +1 -1
  55. package/dist/{curry-order-rules-BLyCSMdZ.js → curry-order-rules-Dage-BeC.js} +1 -1
  56. package/dist/{curry-order-rules-BLyCSMdZ.js.map → curry-order-rules-Dage-BeC.js.map} +1 -1
  57. package/dist/curry.cjs +1 -1
  58. package/dist/curry.cjs.map +1 -1
  59. package/dist/curry.js +1 -1
  60. package/dist/curry.js.map +1 -1
  61. package/dist/debounce.cjs.map +1 -1
  62. package/dist/debounce.js.map +1 -1
  63. package/dist/default-to.cjs +1 -1
  64. package/dist/default-to.cjs.map +1 -1
  65. package/dist/default-to.js.map +1 -1
  66. package/dist/difference-with.cjs +1 -1
  67. package/dist/difference-with.cjs.map +1 -1
  68. package/dist/difference-with.js +1 -1
  69. package/dist/difference-with.js.map +1 -1
  70. package/dist/difference.cjs +1 -1
  71. package/dist/difference.cjs.map +1 -1
  72. package/dist/difference.js +1 -1
  73. package/dist/difference.js.map +1 -1
  74. package/dist/divide.cjs +1 -1
  75. package/dist/divide.cjs.map +1 -1
  76. package/dist/divide.js.map +1 -1
  77. package/dist/do-nothing.cjs.map +1 -1
  78. package/dist/do-nothing.js.map +1 -1
  79. package/dist/drop-first-by.cjs +1 -1
  80. package/dist/drop-first-by.cjs.map +1 -1
  81. package/dist/drop-first-by.js +1 -1
  82. package/dist/drop-first-by.js.map +1 -1
  83. package/dist/drop-last-while.cjs +1 -1
  84. package/dist/drop-last-while.cjs.map +1 -1
  85. package/dist/drop-last-while.js.map +1 -1
  86. package/dist/drop-last.cjs +1 -1
  87. package/dist/drop-last.cjs.map +1 -1
  88. package/dist/drop-last.js.map +1 -1
  89. package/dist/drop-while.cjs +1 -1
  90. package/dist/drop-while.cjs.map +1 -1
  91. package/dist/drop-while.js.map +1 -1
  92. package/dist/drop.cjs +1 -1
  93. package/dist/drop.cjs.map +1 -1
  94. package/dist/drop.js +1 -1
  95. package/dist/drop.js.map +1 -1
  96. package/dist/ends-with.cjs +1 -1
  97. package/dist/ends-with.cjs.map +1 -1
  98. package/dist/ends-with.js.map +1 -1
  99. package/dist/entries.cjs +1 -1
  100. package/dist/entries.cjs.map +1 -1
  101. package/dist/entries.js.map +1 -1
  102. package/dist/evolve.cjs +1 -1
  103. package/dist/evolve.cjs.map +1 -1
  104. package/dist/evolve.js.map +1 -1
  105. package/dist/filter.cjs +1 -1
  106. package/dist/filter.cjs.map +1 -1
  107. package/dist/filter.js +1 -1
  108. package/dist/filter.js.map +1 -1
  109. package/dist/find-index.cjs +1 -1
  110. package/dist/find-index.cjs.map +1 -1
  111. package/dist/find-index.js.map +1 -1
  112. package/dist/find-last-index.cjs +1 -1
  113. package/dist/find-last-index.cjs.map +1 -1
  114. package/dist/find-last-index.js.map +1 -1
  115. package/dist/find-last.cjs +1 -1
  116. package/dist/find-last.cjs.map +1 -1
  117. package/dist/find-last.js.map +1 -1
  118. package/dist/find.cjs +1 -1
  119. package/dist/find.cjs.map +1 -1
  120. package/dist/find.js +1 -1
  121. package/dist/find.js.map +1 -1
  122. package/dist/first-by.cjs +1 -1
  123. package/dist/first-by.cjs.map +1 -1
  124. package/dist/first-by.js +1 -1
  125. package/dist/first-by.js.map +1 -1
  126. package/dist/first.cjs +1 -1
  127. package/dist/first.cjs.map +1 -1
  128. package/dist/first.js +1 -1
  129. package/dist/first.js.map +1 -1
  130. package/dist/flat-map.cjs +1 -1
  131. package/dist/flat-map.cjs.map +1 -1
  132. package/dist/flat-map.js.map +1 -1
  133. package/dist/flat.cjs +1 -1
  134. package/dist/flat.cjs.map +1 -1
  135. package/dist/flat.js +1 -1
  136. package/dist/flat.js.map +1 -1
  137. package/dist/floor.cjs +1 -1
  138. package/dist/floor.cjs.map +1 -1
  139. package/dist/floor.js +1 -1
  140. package/dist/floor.js.map +1 -1
  141. package/dist/for-each-obj.cjs +1 -1
  142. package/dist/for-each-obj.cjs.map +1 -1
  143. package/dist/for-each-obj.js.map +1 -1
  144. package/dist/for-each.cjs +1 -1
  145. package/dist/for-each.cjs.map +1 -1
  146. package/dist/for-each.js.map +1 -1
  147. package/dist/from-entries.cjs +1 -1
  148. package/dist/from-entries.cjs.map +1 -1
  149. package/dist/from-entries.js.map +1 -1
  150. package/dist/from-keys.cjs +1 -1
  151. package/dist/from-keys.cjs.map +1 -1
  152. package/dist/from-keys.js.map +1 -1
  153. package/dist/funnel.cjs.map +1 -1
  154. package/dist/funnel.js.map +1 -1
  155. package/dist/group-by-prop.cjs +1 -1
  156. package/dist/group-by-prop.cjs.map +1 -1
  157. package/dist/group-by-prop.js.map +1 -1
  158. package/dist/group-by.cjs +1 -1
  159. package/dist/group-by.cjs.map +1 -1
  160. package/dist/group-by.js.map +1 -1
  161. package/dist/has-at-least.cjs +1 -1
  162. package/dist/has-at-least.cjs.map +1 -1
  163. package/dist/has-at-least.js.map +1 -1
  164. package/dist/has-prop.cjs +2 -0
  165. package/dist/has-prop.cjs.map +1 -0
  166. package/dist/has-prop.js +2 -0
  167. package/dist/has-prop.js.map +1 -0
  168. package/dist/has-sub-object.cjs +1 -1
  169. package/dist/has-sub-object.cjs.map +1 -1
  170. package/dist/has-sub-object.js.map +1 -1
  171. package/dist/heap-BK0Y5t1Y.cjs +2 -0
  172. package/dist/{heap-C0zPQGC0.cjs.map → heap-BK0Y5t1Y.cjs.map} +1 -1
  173. package/dist/{heap-M6D40vkc.js → heap-CL5ahv5n.js} +2 -2
  174. package/dist/{heap-M6D40vkc.js.map → heap-CL5ahv5n.js.map} +1 -1
  175. package/dist/human-readable-file-size.cjs.map +1 -1
  176. package/dist/human-readable-file-size.js.map +1 -1
  177. package/dist/identity.cjs.map +1 -1
  178. package/dist/identity.js.map +1 -1
  179. package/dist/index-by.cjs +1 -1
  180. package/dist/index-by.cjs.map +1 -1
  181. package/dist/index-by.js.map +1 -1
  182. package/dist/index.cjs +1 -1
  183. package/dist/index.cjs.map +1 -1
  184. package/dist/index.d.cts +174 -202
  185. package/dist/index.d.cts.map +1 -1
  186. package/dist/index.d.ts +174 -202
  187. package/dist/index.d.ts.map +1 -1
  188. package/dist/index.js +1 -1
  189. package/dist/index.js.map +1 -1
  190. package/dist/intersection-with.cjs +1 -1
  191. package/dist/intersection-with.cjs.map +1 -1
  192. package/dist/intersection-with.js +1 -1
  193. package/dist/intersection-with.js.map +1 -1
  194. package/dist/intersection.cjs +1 -1
  195. package/dist/intersection.cjs.map +1 -1
  196. package/dist/intersection.js +1 -1
  197. package/dist/intersection.js.map +1 -1
  198. package/dist/invert.cjs +1 -1
  199. package/dist/invert.cjs.map +1 -1
  200. package/dist/invert.js.map +1 -1
  201. package/dist/is-array.cjs.map +1 -1
  202. package/dist/is-array.js.map +1 -1
  203. package/dist/is-big-int.cjs.map +1 -1
  204. package/dist/is-big-int.js.map +1 -1
  205. package/dist/is-boolean.cjs.map +1 -1
  206. package/dist/is-boolean.js.map +1 -1
  207. package/dist/is-date.cjs.map +1 -1
  208. package/dist/is-date.js.map +1 -1
  209. package/dist/is-deep-equal.cjs +1 -1
  210. package/dist/is-deep-equal.cjs.map +1 -1
  211. package/dist/is-deep-equal.js +1 -1
  212. package/dist/is-deep-equal.js.map +1 -1
  213. package/dist/is-defined.cjs.map +1 -1
  214. package/dist/is-defined.js.map +1 -1
  215. package/dist/is-empty.cjs.map +1 -1
  216. package/dist/is-empty.js.map +1 -1
  217. package/dist/is-emptyish.cjs.map +1 -1
  218. package/dist/is-emptyish.js.map +1 -1
  219. package/dist/is-error.cjs.map +1 -1
  220. package/dist/is-error.js.map +1 -1
  221. package/dist/is-function.cjs.map +1 -1
  222. package/dist/is-function.js.map +1 -1
  223. package/dist/is-included-in.cjs.map +1 -1
  224. package/dist/is-included-in.js.map +1 -1
  225. package/dist/is-non-null.cjs.map +1 -1
  226. package/dist/is-non-null.js.map +1 -1
  227. package/dist/is-non-nullish.cjs.map +1 -1
  228. package/dist/is-non-nullish.js.map +1 -1
  229. package/dist/is-not.cjs.map +1 -1
  230. package/dist/is-not.js.map +1 -1
  231. package/dist/is-nullish.cjs.map +1 -1
  232. package/dist/is-nullish.js.map +1 -1
  233. package/dist/is-number.cjs.map +1 -1
  234. package/dist/is-number.js.map +1 -1
  235. package/dist/is-object-type.cjs.map +1 -1
  236. package/dist/is-object-type.js.map +1 -1
  237. package/dist/is-plain-object.cjs.map +1 -1
  238. package/dist/is-plain-object.js.map +1 -1
  239. package/dist/is-promise.cjs.map +1 -1
  240. package/dist/is-promise.js.map +1 -1
  241. package/dist/is-shallow-equal.cjs +1 -1
  242. package/dist/is-shallow-equal.cjs.map +1 -1
  243. package/dist/is-shallow-equal.js.map +1 -1
  244. package/dist/is-strict-equal.cjs +1 -1
  245. package/dist/is-strict-equal.cjs.map +1 -1
  246. package/dist/is-strict-equal.js.map +1 -1
  247. package/dist/is-string.cjs.map +1 -1
  248. package/dist/is-string.js.map +1 -1
  249. package/dist/is-symbol.cjs.map +1 -1
  250. package/dist/is-symbol.js.map +1 -1
  251. package/dist/is-truthy.cjs.map +1 -1
  252. package/dist/is-truthy.js.map +1 -1
  253. package/dist/join.cjs +1 -1
  254. package/dist/join.cjs.map +1 -1
  255. package/dist/join.js.map +1 -1
  256. package/dist/key-codes.cjs.map +1 -1
  257. package/dist/key-codes.js.map +1 -1
  258. package/dist/keys.cjs +1 -1
  259. package/dist/keys.cjs.map +1 -1
  260. package/dist/keys.js.map +1 -1
  261. package/dist/last.cjs +1 -1
  262. package/dist/last.cjs.map +1 -1
  263. package/dist/last.js.map +1 -1
  264. package/dist/{lazy-data-last-impl-Vt_M0l7X.js → lazy-data-last-impl--3B10z3s.js} +1 -1
  265. package/dist/{lazy-data-last-impl-Vt_M0l7X.js.map → lazy-data-last-impl--3B10z3s.js.map} +1 -1
  266. package/dist/lazy-data-last-impl-Dd5zjCfU.cjs +2 -0
  267. package/dist/{lazy-data-last-impl-B05ZpguF.cjs.map → lazy-data-last-impl-Dd5zjCfU.cjs.map} +1 -1
  268. package/dist/length.cjs +1 -1
  269. package/dist/length.cjs.map +1 -1
  270. package/dist/length.js.map +1 -1
  271. package/dist/map-keys.cjs +1 -1
  272. package/dist/map-keys.cjs.map +1 -1
  273. package/dist/map-keys.js.map +1 -1
  274. package/dist/map-to-obj.cjs +1 -1
  275. package/dist/map-to-obj.cjs.map +1 -1
  276. package/dist/map-to-obj.js.map +1 -1
  277. package/dist/map-values.cjs +1 -1
  278. package/dist/map-values.cjs.map +1 -1
  279. package/dist/map-values.js.map +1 -1
  280. package/dist/map-with-feedback.cjs +1 -1
  281. package/dist/map-with-feedback.cjs.map +1 -1
  282. package/dist/map-with-feedback.js +1 -1
  283. package/dist/map-with-feedback.js.map +1 -1
  284. package/dist/map.cjs +1 -1
  285. package/dist/map.cjs.map +1 -1
  286. package/dist/map.js.map +1 -1
  287. package/dist/mean-by.cjs +1 -1
  288. package/dist/mean-by.cjs.map +1 -1
  289. package/dist/mean-by.js.map +1 -1
  290. package/dist/mean.cjs +1 -1
  291. package/dist/mean.cjs.map +1 -1
  292. package/dist/mean.js.map +1 -1
  293. package/dist/median.cjs +1 -1
  294. package/dist/median.cjs.map +1 -1
  295. package/dist/median.js.map +1 -1
  296. package/dist/merge-all.cjs.map +1 -1
  297. package/dist/merge-all.js.map +1 -1
  298. package/dist/merge-deep.cjs +1 -1
  299. package/dist/merge-deep.cjs.map +1 -1
  300. package/dist/merge-deep.js.map +1 -1
  301. package/dist/merge.cjs +1 -1
  302. package/dist/merge.cjs.map +1 -1
  303. package/dist/merge.js.map +1 -1
  304. package/dist/multiply.cjs +1 -1
  305. package/dist/multiply.cjs.map +1 -1
  306. package/dist/multiply.js.map +1 -1
  307. package/dist/{nth-by-zZ3RM-mR.cjs → nth-by-BrkoqeV2.cjs} +2 -2
  308. package/dist/{nth-by-zZ3RM-mR.cjs.map → nth-by-BrkoqeV2.cjs.map} +1 -1
  309. package/dist/{nth-by-DhfNV5xd.js → nth-by-DGcGGvJX.js} +2 -2
  310. package/dist/{nth-by-DhfNV5xd.js.map → nth-by-DGcGGvJX.js.map} +1 -1
  311. package/dist/nth-by.cjs +1 -1
  312. package/dist/nth-by.js +1 -1
  313. package/dist/obj-of.cjs +1 -1
  314. package/dist/obj-of.cjs.map +1 -1
  315. package/dist/obj-of.js.map +1 -1
  316. package/dist/omit-by.cjs +1 -1
  317. package/dist/omit-by.cjs.map +1 -1
  318. package/dist/omit-by.js.map +1 -1
  319. package/dist/omit.cjs +1 -1
  320. package/dist/omit.cjs.map +1 -1
  321. package/dist/omit.js.map +1 -1
  322. package/dist/once.cjs.map +1 -1
  323. package/dist/once.js.map +1 -1
  324. package/dist/only.cjs +1 -1
  325. package/dist/only.cjs.map +1 -1
  326. package/dist/only.js.map +1 -1
  327. package/dist/partial-bind.cjs.map +1 -1
  328. package/dist/partial-bind.js.map +1 -1
  329. package/dist/partial-last-bind.cjs.map +1 -1
  330. package/dist/partial-last-bind.js.map +1 -1
  331. package/dist/partition.cjs +1 -1
  332. package/dist/partition.cjs.map +1 -1
  333. package/dist/partition.js.map +1 -1
  334. package/dist/path-or.cjs +1 -1
  335. package/dist/path-or.cjs.map +1 -1
  336. package/dist/path-or.js.map +1 -1
  337. package/dist/pick-by.cjs +1 -1
  338. package/dist/pick-by.cjs.map +1 -1
  339. package/dist/pick-by.js.map +1 -1
  340. package/dist/pick.cjs +1 -1
  341. package/dist/pick.cjs.map +1 -1
  342. package/dist/pick.js.map +1 -1
  343. package/dist/pipe.cjs +1 -1
  344. package/dist/pipe.cjs.map +1 -1
  345. package/dist/pipe.js +1 -1
  346. package/dist/pipe.js.map +1 -1
  347. package/dist/piped.cjs +1 -1
  348. package/dist/piped.cjs.map +1 -1
  349. package/dist/piped.js.map +1 -1
  350. package/dist/product.cjs +1 -1
  351. package/dist/product.cjs.map +1 -1
  352. package/dist/product.js.map +1 -1
  353. package/dist/prop.cjs.map +1 -1
  354. package/dist/prop.js.map +1 -1
  355. package/dist/pull-object.cjs +1 -1
  356. package/dist/pull-object.cjs.map +1 -1
  357. package/dist/pull-object.js.map +1 -1
  358. package/dist/random-big-int.cjs.map +1 -1
  359. package/dist/random-big-int.js.map +1 -1
  360. package/dist/random-integer.cjs.map +1 -1
  361. package/dist/random-integer.js.map +1 -1
  362. package/dist/random-string.cjs +1 -1
  363. package/dist/random-string.cjs.map +1 -1
  364. package/dist/random-string.js.map +1 -1
  365. package/dist/range.cjs +1 -1
  366. package/dist/range.cjs.map +1 -1
  367. package/dist/range.js.map +1 -1
  368. package/dist/rank-by.cjs +1 -1
  369. package/dist/rank-by.cjs.map +1 -1
  370. package/dist/rank-by.js +1 -1
  371. package/dist/rank-by.js.map +1 -1
  372. package/dist/reduce.cjs +1 -1
  373. package/dist/reduce.cjs.map +1 -1
  374. package/dist/reduce.js.map +1 -1
  375. package/dist/reverse.cjs +1 -1
  376. package/dist/reverse.cjs.map +1 -1
  377. package/dist/reverse.js.map +1 -1
  378. package/dist/round.cjs +1 -1
  379. package/dist/round.cjs.map +1 -1
  380. package/dist/round.js +1 -1
  381. package/dist/round.js.map +1 -1
  382. package/dist/sample.cjs +1 -1
  383. package/dist/sample.cjs.map +1 -1
  384. package/dist/sample.js.map +1 -1
  385. package/dist/set-path.cjs +1 -1
  386. package/dist/set-path.cjs.map +1 -1
  387. package/dist/set-path.js.map +1 -1
  388. package/dist/set.cjs +1 -1
  389. package/dist/set.cjs.map +1 -1
  390. package/dist/set.js.map +1 -1
  391. package/dist/shuffle.cjs +1 -1
  392. package/dist/shuffle.cjs.map +1 -1
  393. package/dist/shuffle.js.map +1 -1
  394. package/dist/sleep.cjs.map +1 -1
  395. package/dist/sleep.js.map +1 -1
  396. package/dist/slice-string.cjs.map +1 -1
  397. package/dist/slice-string.js.map +1 -1
  398. package/dist/slugify.cjs.map +1 -1
  399. package/dist/slugify.js.map +1 -1
  400. package/dist/sort-by.cjs +1 -1
  401. package/dist/sort-by.cjs.map +1 -1
  402. package/dist/sort-by.js +1 -1
  403. package/dist/sort-by.js.map +1 -1
  404. package/dist/sort.cjs +1 -1
  405. package/dist/sort.cjs.map +1 -1
  406. package/dist/sort.js.map +1 -1
  407. package/dist/sorted-index-by.cjs +1 -1
  408. package/dist/sorted-index-by.cjs.map +1 -1
  409. package/dist/sorted-index-by.js +1 -1
  410. package/dist/sorted-index-by.js.map +1 -1
  411. package/dist/sorted-index-with.cjs +1 -1
  412. package/dist/sorted-index-with.cjs.map +1 -1
  413. package/dist/sorted-index-with.js +1 -1
  414. package/dist/sorted-index-with.js.map +1 -1
  415. package/dist/sorted-index.cjs +1 -1
  416. package/dist/sorted-index.cjs.map +1 -1
  417. package/dist/sorted-index.js +1 -1
  418. package/dist/sorted-index.js.map +1 -1
  419. package/dist/sorted-last-index-by.cjs +1 -1
  420. package/dist/sorted-last-index-by.cjs.map +1 -1
  421. package/dist/sorted-last-index-by.js +1 -1
  422. package/dist/sorted-last-index-by.js.map +1 -1
  423. package/dist/sorted-last-index.cjs +1 -1
  424. package/dist/sorted-last-index.cjs.map +1 -1
  425. package/dist/sorted-last-index.js +1 -1
  426. package/dist/sorted-last-index.js.map +1 -1
  427. package/dist/splice.cjs +1 -1
  428. package/dist/splice.cjs.map +1 -1
  429. package/dist/splice.js +1 -1
  430. package/dist/splice.js.map +1 -1
  431. package/dist/split-at.cjs +1 -1
  432. package/dist/split-at.cjs.map +1 -1
  433. package/dist/split-at.js.map +1 -1
  434. package/dist/split-when.cjs +1 -1
  435. package/dist/split-when.cjs.map +1 -1
  436. package/dist/split-when.js.map +1 -1
  437. package/dist/split.cjs.map +1 -1
  438. package/dist/split.js.map +1 -1
  439. package/dist/starts-with.cjs +1 -1
  440. package/dist/starts-with.cjs.map +1 -1
  441. package/dist/starts-with.js.map +1 -1
  442. package/dist/string-to-path.cjs.map +1 -1
  443. package/dist/string-to-path.js.map +1 -1
  444. package/dist/subtract.cjs +1 -1
  445. package/dist/subtract.cjs.map +1 -1
  446. package/dist/subtract.js.map +1 -1
  447. package/dist/sum-by.cjs +1 -1
  448. package/dist/sum-by.cjs.map +1 -1
  449. package/dist/sum-by.js.map +1 -1
  450. package/dist/sum.cjs +1 -1
  451. package/dist/sum.cjs.map +1 -1
  452. package/dist/sum.js.map +1 -1
  453. package/dist/swap-in-place-CllcD0HG.cjs +2 -0
  454. package/dist/{swap-in-place-D1vasegg.cjs.map → swap-in-place-CllcD0HG.cjs.map} +1 -1
  455. package/dist/{swap-in-place-BzNaxwB3.js → swap-in-place-ubtnp8en.js} +1 -1
  456. package/dist/{swap-in-place-BzNaxwB3.js.map → swap-in-place-ubtnp8en.js.map} +1 -1
  457. package/dist/swap-indices.cjs +1 -1
  458. package/dist/swap-indices.cjs.map +1 -1
  459. package/dist/swap-indices.js.map +1 -1
  460. package/dist/swap-props.cjs +1 -1
  461. package/dist/swap-props.cjs.map +1 -1
  462. package/dist/swap-props.js.map +1 -1
  463. package/dist/take-first-by.cjs +1 -1
  464. package/dist/take-first-by.cjs.map +1 -1
  465. package/dist/take-first-by.js +1 -1
  466. package/dist/take-first-by.js.map +1 -1
  467. package/dist/take-last-while.cjs +1 -1
  468. package/dist/take-last-while.cjs.map +1 -1
  469. package/dist/take-last-while.js.map +1 -1
  470. package/dist/take-last.cjs +1 -1
  471. package/dist/take-last.cjs.map +1 -1
  472. package/dist/take-last.js.map +1 -1
  473. package/dist/take-while.cjs +1 -1
  474. package/dist/take-while.cjs.map +1 -1
  475. package/dist/take-while.js.map +1 -1
  476. package/dist/take.cjs +1 -1
  477. package/dist/take.cjs.map +1 -1
  478. package/dist/take.js +1 -1
  479. package/dist/take.js.map +1 -1
  480. package/dist/tap.cjs +1 -1
  481. package/dist/tap.cjs.map +1 -1
  482. package/dist/tap.js.map +1 -1
  483. package/dist/times.cjs +1 -1
  484. package/dist/times.cjs.map +1 -1
  485. package/dist/times.js.map +1 -1
  486. package/dist/to-camel-case.cjs +1 -1
  487. package/dist/to-camel-case.cjs.map +1 -1
  488. package/dist/to-camel-case.js +1 -1
  489. package/dist/to-camel-case.js.map +1 -1
  490. package/dist/to-kebab-case.cjs +1 -1
  491. package/dist/to-kebab-case.cjs.map +1 -1
  492. package/dist/to-kebab-case.js +1 -1
  493. package/dist/to-kebab-case.js.map +1 -1
  494. package/dist/to-lower-case.cjs +1 -1
  495. package/dist/to-lower-case.cjs.map +1 -1
  496. package/dist/to-lower-case.js.map +1 -1
  497. package/dist/to-single-BOkjnmkm.cjs +2 -0
  498. package/dist/{to-single-BunGuk7o.cjs.map → to-single-BOkjnmkm.cjs.map} +1 -1
  499. package/dist/{to-single-XEXXW73e.js → to-single-D6t2BxVq.js} +1 -1
  500. package/dist/{to-single-XEXXW73e.js.map → to-single-D6t2BxVq.js.map} +1 -1
  501. package/dist/to-snake-case.cjs +1 -1
  502. package/dist/to-snake-case.cjs.map +1 -1
  503. package/dist/to-snake-case.js +1 -1
  504. package/dist/to-snake-case.js.map +1 -1
  505. package/dist/to-title-case.cjs +1 -1
  506. package/dist/to-title-case.cjs.map +1 -1
  507. package/dist/to-title-case.js +1 -1
  508. package/dist/to-title-case.js.map +1 -1
  509. package/dist/to-upper-case.cjs +1 -1
  510. package/dist/to-upper-case.cjs.map +1 -1
  511. package/dist/to-upper-case.js.map +1 -1
  512. package/dist/truncate.cjs.map +1 -1
  513. package/dist/truncate.js.map +1 -1
  514. package/dist/uncapitalize.cjs +1 -1
  515. package/dist/uncapitalize.cjs.map +1 -1
  516. package/dist/uncapitalize.js.map +1 -1
  517. package/dist/unique-by.cjs +1 -1
  518. package/dist/unique-by.cjs.map +1 -1
  519. package/dist/unique-by.js +1 -1
  520. package/dist/unique-by.js.map +1 -1
  521. package/dist/unique-with.cjs +1 -1
  522. package/dist/unique-with.cjs.map +1 -1
  523. package/dist/unique-with.js +1 -1
  524. package/dist/unique-with.js.map +1 -1
  525. package/dist/unique.cjs +1 -1
  526. package/dist/unique.cjs.map +1 -1
  527. package/dist/unique.js +1 -1
  528. package/dist/unique.js.map +1 -1
  529. package/dist/utility-evaluators-BGM19SpK.cjs +2 -0
  530. package/dist/{utility-evaluators-C8koSp9T.cjs.map → utility-evaluators-BGM19SpK.cjs.map} +1 -1
  531. package/dist/{utility-evaluators-ZAaUtL2Z.js → utility-evaluators-DDW55xeL.js} +1 -1
  532. package/dist/{utility-evaluators-ZAaUtL2Z.js.map → utility-evaluators-DDW55xeL.js.map} +1 -1
  533. package/dist/values.cjs +1 -1
  534. package/dist/values.cjs.map +1 -1
  535. package/dist/values.js.map +1 -1
  536. package/dist/when.cjs.map +1 -1
  537. package/dist/when.js.map +1 -1
  538. package/dist/{with-precision-CgRuf7Wl.js → with-precision-D-84B_By.js} +1 -1
  539. package/dist/{with-precision-CgRuf7Wl.js.map → with-precision-D-84B_By.js.map} +1 -1
  540. package/dist/{with-precision-DVi9325n.cjs → with-precision-Dy5W6bdk.cjs} +2 -2
  541. package/dist/{with-precision-DVi9325n.cjs.map → with-precision-Dy5W6bdk.cjs.map} +1 -1
  542. package/dist/{words-_h74qi45.cjs → words-B-9EXtsW.cjs} +2 -2
  543. package/dist/{words-_h74qi45.cjs.map → words-B-9EXtsW.cjs.map} +1 -1
  544. package/dist/{words-B9lX8euz.js → words-CN1Qil5U.js} +1 -1
  545. package/dist/{words-B9lX8euz.js.map → words-CN1Qil5U.js.map} +1 -1
  546. package/dist/zip-with.cjs +1 -1
  547. package/dist/zip-with.cjs.map +1 -1
  548. package/dist/zip-with.js +1 -1
  549. package/dist/zip-with.js.map +1 -1
  550. package/dist/zip.cjs +1 -1
  551. package/dist/zip.cjs.map +1 -1
  552. package/dist/zip.js.map +1 -1
  553. package/package.json +11 -11
  554. package/dist/binary-search-cutoff-index-CLFtXYPc.cjs +0 -2
  555. package/dist/conditional-3wcaMG9k.cjs +0 -2
  556. package/dist/conditional-3wcaMG9k.cjs.map +0 -1
  557. package/dist/conditional-CTEJD5TX.js +0 -2
  558. package/dist/conditional-CTEJD5TX.js.map +0 -1
  559. package/dist/heap-C0zPQGC0.cjs +0 -2
  560. package/dist/lazy-data-last-impl-B05ZpguF.cjs +0 -2
  561. package/dist/swap-in-place-D1vasegg.cjs +0 -2
  562. package/dist/to-single-BunGuk7o.cjs +0 -2
  563. package/dist/utility-evaluators-C8koSp9T.cjs +0 -2
@@ -1 +1 @@
1
- {"version":3,"file":"is-emptyish.js","names":[],"sources":["../src/is-emptyish.ts"],"sourcesContent":["import type {\n And,\n HasRequiredKeys,\n IsAny,\n IsEqual,\n IsNever,\n IsNumericLiteral,\n IsUnknown,\n OmitIndexSignature,\n Or,\n Tagged,\n ValueOf,\n} from 'type-fest';\nimport type { HasWritableKeys } from './internal/types/has-writable-keys';\nimport type { TupleParts } from './internal/types/tuple-parts';\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars -- we use a non-exported unique symbol to prevent users from faking our return type.\ndeclare const EMPTYISH_BRAND: unique symbol;\n\n// Because our function is a type-predicate and it narrows the input based on\n// the result of our type, we sometimes need a way to \"turn off\" narrowing while\n// still returning the input type. By tagging/branding our return type we stop\n// TypeScript from narrowing it while still allowing it to be used as if it was\n// the input type (because it still extends the type).\ntype Empty<T> = Tagged<T, typeof EMPTYISH_BRAND>;\n\n// The goal of this type is to return the empty \"view\" of the input type. This\n// makes it possible for TypeScript to narrow it precisely.\ntype Emptyish<T>\n // There are effectively 4 types that can be empty:\n = | (T extends string ? '' : never)\n | (T extends object ? EmptyishObjectLike<T> : never)\n | (T extends null ? null : never)\n | (T extends undefined ? undefined : never);\n\n// Because of TypeScript's duck-typing, a lot of sub-types of `object` can\n// extend each other so we need to cascade between the different \"kinds\" of\n// objects.\ntype EmptyishObjectLike<T extends object> = T extends ReadonlyArray<unknown>\n ? EmptyishArray<T>\n : T extends ReadonlyMap<infer Key, unknown>\n ? T extends Map<unknown, unknown>\n ? // Mutable maps should remain mutable so we can't narrow them down.\n Empty<T>\n : // But immutable maps could be rewritten to prevent any mutations.\n ReadonlyMap<Key, never>\n : T extends ReadonlySet<unknown>\n ? T extends Set<unknown>\n ? // Mutable sets should remain mutable so we can't narrow them down.\n Empty<T>\n : // But immutable sets could be rewritten to prevent any mutations.\n ReadonlySet<never>\n : EmptyishObject<T>;\n\ntype EmptyishArray<T extends ReadonlyArray<unknown>> = T extends readonly []\n ? // By returning T we effectively narrow the \"else\" branch to `never`.\n T\n : And<\n IsEqual<TupleParts<T>['required'], []>,\n IsEqual<TupleParts<T>['suffix'], []>\n > extends true\n ? T extends Array<unknown>\n ? // A mutable array should remain mutable so we can't narrow it down.\n Empty<T>\n : // But immutable arrays could be rewritten to prevent any mutations.\n readonly []\n : // An array with a required prefix or suffix would never be empty, we can\n // use that fact to narrow the \"if\" branch to `never`.\n never;\n\ntype EmptyishObject<T extends object> = T extends {\n length: infer Length extends number;\n}\n ? T extends string\n ? // When a string is tagged/branded it also extends `object` and also has\n // a `length` prop so we need to prevent handling it because it's\n // irrelevant here!\n never\n : // Because of how the implementation works, we need to consider any object\n // with a `length` prop as potentially \"empty\".\n EmptyishArbitrary<T, Length>\n : T extends { size: infer Size extends number }\n ? // Because of how the implementation works, we need to consider any object\n // with a `size` prop as potentially \"empty\".\n EmptyishArbitrary<T, Size>\n : IsNever<ValueOf<T>> extends true\n ? // This handles empty objects; by returning T we effectively narrow the\n // \"else\" branch to `never`.\n T\n : HasRequiredKeys<OmitIndexSignature<T>> extends true\n ? // If the object has required keys it can never be empty, we can use\n // that fact to narrow the \"if\" branch to `never`.\n never\n : HasWritableKeys<T> extends true\n ? // A mutable object should remain mutable so we can't narrow it\n // down.\n Empty<T>\n : // But immutable objects could be rewritten to prevent any\n // mutations.\n { readonly [P in keyof T]: never };\n\n// We use certain props to check for emptiness effectively, but that means we\n// will return those values for any object that has them. Because we don't know\n// anything about those objects we need to be careful about narrowing.\ntype EmptyishArbitrary<T, N>\n = IsNumericLiteral<N> extends true\n ? [0] extends [N]\n ? [N] extends [0]\n ? // If the prop is a literal 0 the object is and always will be empty\n // so we can return it to narrow the \"else\" branch as `never`.\n T\n : // If it accepts 0, but might accept other values too we need to\n // consider the object mutable and not narrow it down.\n Empty<T>\n : // If the prop will never be 0 we can say it will never be empty and can\n // return `never` for the \"if\" branch.\n never\n : // If the prop isn't a literal value we don't know enough about the object\n // and should consider it mutable.\n Empty<T>;\n\n// Overly generic types interfere with our already pretty complex return type.\n// To make our lives easier we can filter them out at the function declaration\n// step and we never need to think about them again.\ntype ShouldNotNarrow<T> = Or<\n Or<IsAny<T>, IsUnknown<T>>,\n IsEqual<\n T,\n // eslint-disable-next-line ts/no-empty-object-type\n {}\n >\n>;\n\n/**\n * A function that checks if the input is empty. Empty is defined as anything\n * exposing a numerical `length`, or `size` property that is equal to `0`. This\n * definition covers strings, arrays, Maps, Sets, plain objects, and custom\n * classes. Additionally, `null` and `undefined` are also considered empty.\n *\n * `number`, `bigint`, `boolean`, `symbol`, and `function` will always return\n * `false`. `RegExp`, `Date`, and weak collections will always return `true`.\n * Classes and Errors are treated as plain objects: if they expose any public\n * property they would be considered non-empty, unless they expose a numerical\n * `length` or `size` property, which defines their emptiness regardless of\n * other properties.\n *\n * This function has *limited* utility at the type level because **negating** it\n * does not yield a useful type in most cases because of TypeScript\n * limitations. Additionally, utilities which accept a narrower input type\n * provide better type-safety on their inputs. In most cases, you should use\n * one of the following functions instead:\n * `isEmpty` - provides better type-safety on inputs by accepting a narrower set of cases.\n * `hasAtLeast` - when the input is just an array/tuple.\n * `isStrictEqual` - when you just need to check for a specific literal value.\n * `isNullish` - when you just care about `null` and `undefined`.\n * `isTruthy` - when you need to also filter `number` and `boolean`.\n *\n * @param data - The variable to check.\n * @signature\n * isEmptyish(data)\n * @example\n * isEmptyish(undefined); //=> true\n * isEmptyish(null); //=> true\n * isEmptyish(''); //=> true\n * isEmptyish([]); //=> true\n * isEmptyish({}); //=> true\n * isEmptyish(new Map()); //=> true\n * isEmptyish(new Set()); //=> true\n * isEmptyish({ a: \"hello\", size: 0 }); //=> true\n * isEmptyish(/abc/); //=> true\n * isEmptyish(new Date()); //=> true\n * isEmptyish(new WeakMap()); //=> true\n *\n * isEmptyish('test'); //=> false\n * isEmptyish([1, 2, 3]); //=> false\n * isEmptyish({ a: \"hello\" }); //=> false\n * isEmptyish({ length: 1 }); //=> false\n * isEmptyish(0); //=> false\n * isEmptyish(true); //=> false\n * isEmptyish(() => {}); //=> false\n * @category Guard\n */\nexport function isEmptyish<T>(\n data: ShouldNotNarrow<T> extends true\n ? never\n : T | Readonly<Emptyish<NoInfer<T>>>,\n): data is ShouldNotNarrow<T> extends true\n ? never\n : T extends unknown\n ? Emptyish<NoInfer<T>>\n : never;\nexport function isEmptyish(data: unknown): boolean;\n\nexport function isEmptyish(data: unknown): boolean {\n // eslint-disable-next-line eqeqeq -- Less code to ship...\n if (data == undefined || data === '') {\n // These are the only literal values that are considered emptyish.\n return true;\n }\n\n if (typeof data !== 'object') {\n // There are no non-object types that could be empty at this point...\n return false;\n }\n\n if ('length' in data && typeof data.length === 'number') {\n // Arrays and array-likes.\n return data.length === 0;\n }\n\n if ('size' in data && typeof data.size === 'number') {\n // Maps and Sets.\n return data.size === 0;\n }\n\n // eslint-disable-next-line no-unreachable-loop -- Instead of taking Object.keys just to check its length, which will be inefficient if the object has a lot of keys, we have a backdoor into an iterator of the object's properties via the `for...in` loop.\n for (const _ in data) {\n return false;\n }\n\n // We can't do a similar optimization for symbol props, so we leave them for\n // the very last check when the object is practically empty. Assuming that\n // even if an object has a symbol prop, it probably doesn't have thousands of\n // them.\n return Object.getOwnPropertySymbols(data).length === 0;\n}\n"],"mappings":"AAiMA,SAAgB,EAAW,EAAwB,CAEjD,GAAI,GAAQ,MAAa,IAAS,GAEhC,MAAO,GAGT,GAAI,OAAO,GAAS,SAElB,MAAO,GAGT,GAAI,WAAY,GAAQ,OAAO,EAAK,QAAW,SAE7C,OAAO,EAAK,SAAW,EAGzB,GAAI,SAAU,GAAQ,OAAO,EAAK,MAAS,SAEzC,OAAO,EAAK,OAAS,EAIvB,IAAK,IAAM,KAAK,EACd,MAAO,GAOT,OAAO,OAAO,sBAAsB,EAAK,CAAC,SAAW"}
1
+ {"version":3,"file":"is-emptyish.js","names":[],"sources":["../src/is-emptyish.ts"],"sourcesContent":["import type {\n HasRequiredKeys,\n IsAny,\n IsEqual,\n IsNever,\n IsNumericLiteral,\n OmitIndexSignature,\n Tagged,\n ValueOf,\n} from 'type-fest';\nimport type { HasWritableKeys } from './internal/types/has-writable-keys';\nimport type { TupleParts } from './internal/types/tuple-parts';\n\n// eslint-disable-next-line ts/no-unused-vars -- we use a non-exported unique symbol to prevent users from faking our return type.\ndeclare const EMPTYISH_BRAND: unique symbol;\n\n// Because our function is a type-predicate and it narrows the input based on\n// the result of our type, we sometimes need a way to \"turn off\" narrowing while\n// still returning the input type. By tagging/branding our return type we stop\n// TypeScript from narrowing it while still allowing it to be used as if it was\n// the input type (because it still extends the type).\ntype Empty<T> = Tagged<T, typeof EMPTYISH_BRAND>;\n\n// The goal of this type is to return the empty \"view\" of the input type. This\n// makes it possible for TypeScript to narrow it precisely.\ntype Emptyish<T>\n // There are effectively 4 types that can be empty:\n = | (T extends string ? '' : never)\n | (T extends object ? EmptyishObjectLike<T> : never)\n | (T extends null ? null : never)\n | (T extends undefined ? undefined : never);\n\n// Because of TypeScript's duck-typing, a lot of sub-types of `object` can\n// extend each other so we need to cascade between the different \"kinds\" of\n// objects.\ntype EmptyishObjectLike<T extends object> = T extends ReadonlyArray<unknown>\n ? EmptyishArray<T>\n : T extends ReadonlyMap<infer Key, unknown>\n ? T extends Map<unknown, unknown>\n ? // Mutable maps should remain mutable so we can't narrow them down.\n Empty<T>\n : // But immutable maps could be rewritten to prevent any mutations.\n ReadonlyMap<Key, never>\n : T extends ReadonlySet<unknown>\n ? T extends Set<unknown>\n ? // Mutable sets should remain mutable so we can't narrow them down.\n Empty<T>\n : // But immutable sets could be rewritten to prevent any mutations.\n ReadonlySet<never>\n : EmptyishObject<T>;\n\ntype EmptyishArray<T extends ReadonlyArray<unknown>> = T extends readonly []\n ? // By returning T we effectively narrow the \"else\" branch to `never`.\n T\n : TupleParts<T>['required'] extends readonly []\n ? TupleParts<T>['suffix'] extends readonly []\n ? T extends Array<unknown>\n ? // A mutable array should remain mutable so we can't narrow it down.\n Empty<T>\n : // But immutable arrays could be rewritten to prevent any mutations.\n readonly []\n : // An array with a required prefix or suffix would never be empty, we\n // can use that fact to narrow the \"if\" branch to `never`.\n never\n : never;\n\ntype EmptyishObject<T extends object> = T extends {\n length: infer Length extends number;\n}\n ? T extends string\n ? // When a string is tagged/branded it also extends `object` and also has\n // a `length` prop so we need to prevent handling it because it's\n // irrelevant here!\n never\n : // Because of how the implementation works, we need to consider any object\n // with a `length` prop as potentially \"empty\".\n EmptyishArbitrary<T, Length>\n : T extends { size: infer Size extends number }\n ? // Because of how the implementation works, we need to consider any object\n // with a `size` prop as potentially \"empty\".\n EmptyishArbitrary<T, Size>\n : IsNever<ValueOf<T>> extends true\n ? // This handles empty objects; by returning T we effectively narrow the\n // \"else\" branch to `never`.\n T\n : HasRequiredKeys<OmitIndexSignature<T>> extends true\n ? // If the object has required keys it can never be empty, we can use\n // that fact to narrow the \"if\" branch to `never`.\n never\n : HasWritableKeys<T> extends true\n ? // A mutable object should remain mutable so we can't narrow it\n // down.\n Empty<T>\n : // But immutable objects could be rewritten to prevent any\n // mutations.\n { readonly [P in keyof T]: never };\n\n// We use certain props to check for emptiness effectively, but that means we\n// will return those values for any object that has them. Because we don't know\n// anything about those objects we need to be careful about narrowing.\ntype EmptyishArbitrary<T, N>\n = IsNumericLiteral<N> extends true\n ? [0] extends [N]\n ? [N] extends [0]\n ? // If the prop is a literal 0 the object is and always will be empty\n // so we can return it to narrow the \"else\" branch as `never`.\n T\n : // If it accepts 0, but might accept other values too we need to\n // consider the object mutable and not narrow it down.\n Empty<T>\n : // If the prop will never be 0 we can say it will never be empty and can\n // return `never` for the \"if\" branch.\n never\n : // If the prop isn't a literal value we don't know enough about the object\n // and should consider it mutable.\n Empty<T>;\n\n// Overly generic types interfere with our already pretty complex return type.\n// To make our lives easier we can filter them out at the function declaration\n// step and we never need to think about them again.\ntype ShouldNotNarrow<T> = unknown extends T\n ? true\n : IsAny<T> extends true\n ? true\n : IsEqual<\n T,\n // eslint-disable-next-line ts/no-empty-object-type\n {}\n > extends true\n ? true\n : false;\n\n/**\n * A function that checks if the input is empty. Empty is defined as anything\n * exposing a numerical `length`, or `size` property that is equal to `0`. This\n * definition covers strings, arrays, Maps, Sets, plain objects, and custom\n * classes. Additionally, `null` and `undefined` are also considered empty.\n *\n * `number`, `bigint`, `boolean`, `symbol`, and `function` will always return\n * `false`. `RegExp`, `Date`, and weak collections will always return `true`.\n * Classes and Errors are treated as plain objects: if they expose any public\n * property they would be considered non-empty, unless they expose a numerical\n * `length` or `size` property, which defines their emptiness regardless of\n * other properties.\n *\n * This function has *limited* utility at the type level because **negating** it\n * does not yield a useful type in most cases because of TypeScript\n * limitations. Additionally, utilities which accept a narrower input type\n * provide better type-safety on their inputs. In most cases, you should use\n * one of the following functions instead:\n * `isEmpty` - provides better type-safety on inputs by accepting a narrower set of cases.\n * `hasAtLeast` - when the input is just an array/tuple.\n * `isStrictEqual` - when you just need to check for a specific literal value.\n * `isNullish` - when you just care about `null` and `undefined`.\n * `isTruthy` - when you need to also filter `number` and `boolean`.\n *\n * @param data - The variable to check.\n * @signature\n * isEmptyish(data)\n * @example\n * isEmptyish(undefined); //=> true\n * isEmptyish(null); //=> true\n * isEmptyish(''); //=> true\n * isEmptyish([]); //=> true\n * isEmptyish({}); //=> true\n * isEmptyish(new Map()); //=> true\n * isEmptyish(new Set()); //=> true\n * isEmptyish({ a: \"hello\", size: 0 }); //=> true\n * isEmptyish(/abc/); //=> true\n * isEmptyish(new Date()); //=> true\n * isEmptyish(new WeakMap()); //=> true\n *\n * isEmptyish('test'); //=> false\n * isEmptyish([1, 2, 3]); //=> false\n * isEmptyish({ a: \"hello\" }); //=> false\n * isEmptyish({ length: 1 }); //=> false\n * isEmptyish(0); //=> false\n * isEmptyish(true); //=> false\n * isEmptyish(() => {}); //=> false\n * @category Guard\n */\nexport function isEmptyish<T>(\n data: ShouldNotNarrow<T> extends true\n ? never\n : T | Readonly<Emptyish<NoInfer<T>>>,\n): data is ShouldNotNarrow<T> extends true\n ? never\n : T extends unknown\n ? Emptyish<NoInfer<T>>\n : never;\nexport function isEmptyish(data: unknown): boolean;\n\nexport function isEmptyish(data: unknown): boolean {\n // eslint-disable-next-line eqeqeq -- Less code to ship...\n if (data == undefined || data === '') {\n // These are the only literal values that are considered emptyish.\n return true;\n }\n\n if (typeof data !== 'object') {\n // There are no non-object types that could be empty at this point...\n return false;\n }\n\n if ('length' in data && typeof data.length === 'number') {\n // Arrays and array-likes.\n return data.length === 0;\n }\n\n if ('size' in data && typeof data.size === 'number') {\n // Maps and Sets.\n return data.size === 0;\n }\n\n // eslint-disable-next-line no-unreachable-loop, no-restricted-syntax -- Instead of taking Object.keys just to check its length, which will be inefficient if the object has a lot of keys, we have a backdoor into an iterator of the object's properties via the `for...in` loop.\n for (const _ in data) {\n return false;\n }\n\n // We can't do a similar optimization for symbol props, so we leave them for\n // the very last check when the object is practically empty. Assuming that\n // even if an object has a symbol prop, it probably doesn't have thousands of\n // them.\n return Object.getOwnPropertySymbols(data).length === 0;\n}\n"],"mappings":"AAgMA,SAAgB,EAAW,EAAwB,CAEjD,GAAI,GAAQ,MAAa,IAAS,GAEhC,MAAO,GAGT,GAAI,OAAO,GAAS,SAElB,MAAO,GAGT,GAAI,WAAY,GAAQ,OAAO,EAAK,QAAW,SAE7C,OAAO,EAAK,SAAW,EAGzB,GAAI,SAAU,GAAQ,OAAO,EAAK,MAAS,SAEzC,OAAO,EAAK,OAAS,EAIvB,IAAK,IAAM,KAAK,EACd,MAAO,GAOT,OAAO,OAAO,sBAAsB,CAAI,CAAC,CAAC,SAAW,CACvD"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-error.cjs","names":[],"sources":["../src/is-error.ts"],"sourcesContent":["type DefinitelyError<T>\n = Extract<T, Error> extends never ? Error : Extract<T, Error>;\n/**\n * A function that checks if the passed parameter is an Error and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is an Error, false otherwise.\n * @signature\n * isError(data)\n * @example\n * isError(new Error('message')) //=> true\n * isError('somethingElse') //=> false\n * @category Guard\n */\nexport function isError<T>(data: Error | T): data is DefinitelyError<T> {\n return data instanceof Error;\n}\n"],"mappings":"mEAcA,SAAgB,EAAW,EAA6C,CACtE,OAAO,aAAgB"}
1
+ {"version":3,"file":"is-error.cjs","names":[],"sources":["../src/is-error.ts"],"sourcesContent":["import type { IsNever } from 'type-fest';\n\ntype DefinitelyError<T>\n = IsNever<Extract<T, Error>> extends true ? Error : Extract<T, Error>;\n/**\n * A function that checks if the passed parameter is an Error and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is an Error, false otherwise.\n * @signature\n * isError(data)\n * @example\n * isError(new Error('message')) //=> true\n * isError('somethingElse') //=> false\n * @category Guard\n */\nexport function isError<T>(data: Error | T): data is DefinitelyError<T> {\n return data instanceof Error;\n}\n"],"mappings":"mEAgBA,SAAgB,EAAW,EAA6C,CACtE,OAAO,aAAgB,KACzB"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-error.js","names":[],"sources":["../src/is-error.ts"],"sourcesContent":["type DefinitelyError<T>\n = Extract<T, Error> extends never ? Error : Extract<T, Error>;\n/**\n * A function that checks if the passed parameter is an Error and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is an Error, false otherwise.\n * @signature\n * isError(data)\n * @example\n * isError(new Error('message')) //=> true\n * isError('somethingElse') //=> false\n * @category Guard\n */\nexport function isError<T>(data: Error | T): data is DefinitelyError<T> {\n return data instanceof Error;\n}\n"],"mappings":"AAcA,SAAgB,EAAW,EAA6C,CACtE,OAAO,aAAgB"}
1
+ {"version":3,"file":"is-error.js","names":[],"sources":["../src/is-error.ts"],"sourcesContent":["import type { IsNever } from 'type-fest';\n\ntype DefinitelyError<T>\n = IsNever<Extract<T, Error>> extends true ? Error : Extract<T, Error>;\n/**\n * A function that checks if the passed parameter is an Error and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is an Error, false otherwise.\n * @signature\n * isError(data)\n * @example\n * isError(new Error('message')) //=> true\n * isError('somethingElse') //=> false\n * @category Guard\n */\nexport function isError<T>(data: Error | T): data is DefinitelyError<T> {\n return data instanceof Error;\n}\n"],"mappings":"AAgBA,SAAgB,EAAW,EAA6C,CACtE,OAAO,aAAgB,KACzB"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-function.cjs","names":[],"sources":["../src/is-function.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\nimport type { StrictFunction } from './internal/types/strict-function';\n\n/**\n * A function that checks if the passed parameter is a Function and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is a Function, false otherwise.\n * @signature\n * isFunction(data)\n * @example\n * isFunction(() => {}) //=> true\n * isFunction('somethingElse') //=> false\n * @category Guard\n */\nexport function isFunction<T>(data: StrictFunction | T): data is NarrowedTo<T, StrictFunction> {\n return typeof data === 'function';\n}\n"],"mappings":"mEAeA,SAAgB,EAAc,EAAiE,CAC7F,OAAO,OAAO,GAAS"}
1
+ {"version":3,"file":"is-function.cjs","names":[],"sources":["../src/is-function.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\nimport type { StrictFunction } from './internal/types/strict-function';\n\n/**\n * A function that checks if the passed parameter is a Function and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is a Function, false otherwise.\n * @signature\n * isFunction(data)\n * @example\n * isFunction(() => {}) //=> true\n * isFunction('somethingElse') //=> false\n * @category Guard\n */\nexport function isFunction<T>(data: StrictFunction | T): data is NarrowedTo<T, StrictFunction> {\n return typeof data === 'function';\n}\n"],"mappings":"mEAeA,SAAgB,EAAc,EAAiE,CAC7F,OAAO,OAAO,GAAS,UACzB"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-function.js","names":[],"sources":["../src/is-function.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\nimport type { StrictFunction } from './internal/types/strict-function';\n\n/**\n * A function that checks if the passed parameter is a Function and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is a Function, false otherwise.\n * @signature\n * isFunction(data)\n * @example\n * isFunction(() => {}) //=> true\n * isFunction('somethingElse') //=> false\n * @category Guard\n */\nexport function isFunction<T>(data: StrictFunction | T): data is NarrowedTo<T, StrictFunction> {\n return typeof data === 'function';\n}\n"],"mappings":"AAeA,SAAgB,EAAc,EAAiE,CAC7F,OAAO,OAAO,GAAS"}
1
+ {"version":3,"file":"is-function.js","names":[],"sources":["../src/is-function.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\nimport type { StrictFunction } from './internal/types/strict-function';\n\n/**\n * A function that checks if the passed parameter is a Function and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is a Function, false otherwise.\n * @signature\n * isFunction(data)\n * @example\n * isFunction(() => {}) //=> true\n * isFunction('somethingElse') //=> false\n * @category Guard\n */\nexport function isFunction<T>(data: StrictFunction | T): data is NarrowedTo<T, StrictFunction> {\n return typeof data === 'function';\n}\n"],"mappings":"AAeA,SAAgB,EAAc,EAAiE,CAC7F,OAAO,OAAO,GAAS,UACzB"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-included-in.cjs","names":[],"sources":["../src/is-included-in.ts"],"sourcesContent":["import type { IsLiteral, IsUnion } from 'type-fest';\nimport type { IterableContainer } from './internal/types/iterable-container';\n\n/**\n * A \"constant\" tuple is a type that has a single runtime value that can fulfil\n * it. This means that it doesn't have any variadic/rest/spread/array parts, and\n * that all it's values are singular (non-union) literals.\n *\n * We use this type to allow narrowing when checking against a set of values\n * defined as a const.\n *\n * @example\n * type T1 = IsConstantTuple<[\"cat\", \"dog\", 3, true]>; // => true;\n * type T2 = IsConstantTuple<[\"cat\" | \"dog\"]>; // false;\n * type T2 = IsConstantTuple<[\"cat\", ...\"cat\"[]]>; // false;\n */\ntype IsConstantTuple<T extends IterableContainer> = T extends readonly []\n ? true\n : T extends readonly [infer Head, ...infer Rest]\n ? IsUnion<Head> extends true\n ? false\n : IsConstantTuple<Rest>\n : false;\n\n/**\n * There is no way to tell Typescript to only narrow the \"accepted\" side of a\n * type-predicate and so in many cases the negated side is also affected, this\n * results in over-narrowing in many cases, breaking typing. For this reason we\n * only want to use the type-predicate variant of `isIncludedIn` when we can\n * assume the result represents the expected types (closely enough). This is not\n * and ideal solution and we will still generate wrong types in some cases (see\n * tests), but it reduces the surface of this problem significantly, while still\n * keeping the utility of `isIncludedIn` for the common cases.\n *\n * TL;DR - The types are narrowable when: T is literal and S is a pure tuple, or\n * when T isn't a literal, but S is.\n *\n * @example\n * const data = 1 as 1 | 2 | 3;\n * const container = [] as (1 | 2)[];\n * if (isIncludedIn(data, container)) {\n * ... it makes sense to narrow data to `1 | 2` as the value `3` is not part\n * ... of the typing of container, so will never result in being true.\n * } else {\n * ... but it doesn't make sense to narrow the value to 3 here, because 1\n * ... and 2 are still valid values for data, when container doesn't include\n * ... them **at runtime**.\n * ... Typescript narrows the _rejected_ branch based on how it narrowed the\n * ... _accepted_ clause, and we can't control that; because our input type\n * ... is `1 | 2 | 3` and the accepted side is `1 | 2`, the rejected side is\n * ... typed `Exclude<1 | 2 | 3, 1 | 2>`, which is `3`.\n * }\n * }\n */\ntype IsNarrowable<T, S extends IterableContainer<T>>\n = IsLiteral<T> extends true\n ? // When T is literal (i.g. it isn't a primitive type like `string` or\n // `number`) then the criteria for narrowing is that the container is a\n // \"pure\" tuple because we *assume* that S represents a constant set of\n // values, and that it's typing also represents it's runtime content 1-\n // for-1. If S isn't a pure tuple it means we can't tell from the typing\n // which of it's values are actually present in runtime so can't use them\n // to narrow correctly.\n IsConstantTuple<S>\n : // When T isn't a literal type but the items in S are we can narrow the\n // type because it won't affect the negated side (`Exclude<number, 3>`\n // is still `number`).\n IsLiteral<S[number]>;\n\n/**\n * Checks if the item is included in the container. This is a wrapper around\n * `Array.prototype.includes` and `Set.prototype.has` and thus relies on the\n * same equality checks that those functions do (which is reference equality,\n * e.g. `===`). In some cases the input's type is also narrowed to the\n * container's item types.\n *\n * Notice that unlike most functions, this function takes a generic item as it's\n * data and **an array** as it's parameter.\n *\n * @param data - The item that is checked.\n * @param container - The items that are checked against.\n * @returns `true` if the item is in the container, or `false` otherwise. In\n * cases the type of `data` is also narrowed down.\n * @signature\n * isIncludedIn(data, container);\n * @example\n * isIncludedIn(2, [1, 2, 3]); // => true\n * isIncludedIn(4, [1, 2, 3]); // => false\n *\n * const data = \"cat\" as \"cat\" | \"dog\" | \"mouse\";\n * isIncludedIn(data, [\"cat\", \"dog\"] as const); // true (typed \"cat\" | \"dog\");\n * @dataFirst\n * @category Guard\n */\nexport function isIncludedIn<T, S extends IterableContainer<T>>(\n data: T,\n container: IsNarrowable<T, S> extends true ? S : never,\n): data is S[number];\nexport function isIncludedIn<T, S extends T>(\n data: T,\n container: IterableContainer<S>,\n): boolean;\n\n/**\n * Checks if the item is included in the container. This is a wrapper around\n * `Array.prototype.includes` and `Set.prototype.has` and thus relies on the\n * same equality checks that those functions do (which is reference equality,\n * e.g. `===`). In some cases the input's type is also narrowed to the\n * container's item types.\n *\n * Notice that unlike most functions, this function takes a generic item as it's\n * data and **an array** as it's parameter.\n *\n * @param container - The items that are checked against.\n * @returns `true` if the item is in the container, or `false` otherwise. In\n * cases the type of `data` is also narrowed down.\n * @signature\n * isIncludedIn(container)(data);\n * @example\n * pipe(2, isIncludedIn([1, 2, 3])); // => true\n * pipe(4, isIncludedIn([1, 2, 3])); // => false\n *\n * const data = \"cat\" as \"cat\" | \"dog\" | \"mouse\";\n * pipe(\n * data,\n * isIncludedIn([\"cat\", \"dog\"] as const),\n * ); // => true (typed \"cat\" | \"dog\");\n * @dataLast\n * @category Guard\n */\nexport function isIncludedIn<T, S extends IterableContainer<T>>(\n container: IsNarrowable<T, S> extends true ? S : never,\n): (data: T) => data is S[number];\nexport function isIncludedIn<T, S extends T>(\n container: IterableContainer<S>,\n): (data: T) => boolean;\n\nexport function isIncludedIn(\n dataOrContainer: unknown,\n container?: ReadonlyArray<unknown>,\n): unknown {\n if (container === undefined) {\n // === dataLast ===\n // We don't use curry here because we can optimize the dataLast case by\n // memoizing a set and accessing it in O(1) time instead of scanning the\n // array **each time** (O(n)) each time.\n const asSet = new Set(dataOrContainer as ReadonlyArray<unknown>);\n return (data: unknown) => asSet.has(data);\n }\n\n // === dataFirst ===\n return container.includes(dataOrContainer);\n}\n"],"mappings":"mEAyIA,SAAgB,EACd,EACA,EACS,CACT,GAAI,IAAc,IAAA,GAAW,CAK3B,IAAM,EAAQ,IAAI,IAAI,EAA0C,CAChE,MAAQ,IAAkB,EAAM,IAAI,EAAK,CAI3C,OAAO,EAAU,SAAS,EAAgB"}
1
+ {"version":3,"file":"is-included-in.cjs","names":[],"sources":["../src/is-included-in.ts"],"sourcesContent":["import type { IsLiteral, IsUnion } from 'type-fest';\nimport type { IterableContainer } from './internal/types/iterable-container';\n\n/**\n * A \"constant\" tuple is a type that has a single runtime value that can fulfil\n * it. This means that it doesn't have any variadic/rest/spread/array parts, and\n * that all it's values are singular (non-union) literals.\n *\n * We use this type to allow narrowing when checking against a set of values\n * defined as a const.\n *\n * @example\n * type T1 = IsConstantTuple<[\"cat\", \"dog\", 3, true]>; // => true;\n * type T2 = IsConstantTuple<[\"cat\" | \"dog\"]>; // false;\n * type T2 = IsConstantTuple<[\"cat\", ...\"cat\"[]]>; // false;\n */\ntype IsConstantTuple<T extends IterableContainer> = T extends readonly []\n ? true\n : T extends readonly [infer Head, ...infer Rest]\n ? IsUnion<Head> extends true\n ? false\n : IsConstantTuple<Rest>\n : false;\n\n/**\n * There is no way to tell Typescript to only narrow the \"accepted\" side of a\n * type-predicate and so in many cases the negated side is also affected, this\n * results in over-narrowing in many cases, breaking typing. For this reason we\n * only want to use the type-predicate variant of `isIncludedIn` when we can\n * assume the result represents the expected types (closely enough). This is not\n * and ideal solution and we will still generate wrong types in some cases (see\n * tests), but it reduces the surface of this problem significantly, while still\n * keeping the utility of `isIncludedIn` for the common cases.\n *\n * TL;DR - The types are narrowable when: T is literal and S is a pure tuple, or\n * when T isn't a literal, but S is.\n *\n * @example\n * const data = 1 as 1 | 2 | 3;\n * const container = [] as (1 | 2)[];\n * if (isIncludedIn(data, container)) {\n * ... it makes sense to narrow data to `1 | 2` as the value `3` is not part\n * ... of the typing of container, so will never result in being true.\n * } else {\n * ... but it doesn't make sense to narrow the value to 3 here, because 1\n * ... and 2 are still valid values for data, when container doesn't include\n * ... them **at runtime**.\n * ... Typescript narrows the _rejected_ branch based on how it narrowed the\n * ... _accepted_ clause, and we can't control that; because our input type\n * ... is `1 | 2 | 3` and the accepted side is `1 | 2`, the rejected side is\n * ... typed `Exclude<1 | 2 | 3, 1 | 2>`, which is `3`.\n * }\n * }\n */\ntype IsNarrowable<T, S extends IterableContainer<T>>\n = IsLiteral<T> extends true\n ? // When T is literal (i.g. it isn't a primitive type like `string` or\n // `number`) then the criteria for narrowing is that the container is a\n // \"pure\" tuple because we *assume* that S represents a constant set of\n // values, and that it's typing also represents it's runtime content 1-\n // for-1. If S isn't a pure tuple it means we can't tell from the typing\n // which of it's values are actually present in runtime so can't use them\n // to narrow correctly.\n IsConstantTuple<S>\n : // When T isn't a literal type but the items in S are we can narrow the\n // type because it won't affect the negated side (`Exclude<number, 3>`\n // is still `number`).\n IsLiteral<S[number]>;\n\n/**\n * Checks if the item is included in the container. This is a wrapper around\n * `Array.prototype.includes` and `Set.prototype.has` and thus relies on the\n * same equality checks that those functions do (which is reference equality,\n * e.g. `===`). In some cases the input's type is also narrowed to the\n * container's item types.\n *\n * Notice that unlike most functions, this function takes a generic item as it's\n * data and **an array** as it's parameter.\n *\n * @param data - The item that is checked.\n * @param container - The items that are checked against.\n * @returns `true` if the item is in the container, or `false` otherwise. In\n * cases the type of `data` is also narrowed down.\n * @signature\n * isIncludedIn(data, container);\n * @example\n * isIncludedIn(2, [1, 2, 3]); // => true\n * isIncludedIn(4, [1, 2, 3]); // => false\n *\n * const data = \"cat\" as \"cat\" | \"dog\" | \"mouse\";\n * isIncludedIn(data, [\"cat\", \"dog\"] as const); // true (typed \"cat\" | \"dog\");\n * @dataFirst\n * @category Guard\n */\nexport function isIncludedIn<T, S extends IterableContainer<T>>(\n data: T,\n container: IsNarrowable<T, S> extends true ? S : never,\n): data is S[number];\nexport function isIncludedIn<T, S extends T>(\n data: T,\n container: IterableContainer<S>,\n): boolean;\n\n/**\n * Checks if the item is included in the container. This is a wrapper around\n * `Array.prototype.includes` and `Set.prototype.has` and thus relies on the\n * same equality checks that those functions do (which is reference equality,\n * e.g. `===`). In some cases the input's type is also narrowed to the\n * container's item types.\n *\n * Notice that unlike most functions, this function takes a generic item as it's\n * data and **an array** as it's parameter.\n *\n * @param container - The items that are checked against.\n * @returns `true` if the item is in the container, or `false` otherwise. In\n * cases the type of `data` is also narrowed down.\n * @signature\n * isIncludedIn(container)(data);\n * @example\n * pipe(2, isIncludedIn([1, 2, 3])); // => true\n * pipe(4, isIncludedIn([1, 2, 3])); // => false\n *\n * const data = \"cat\" as \"cat\" | \"dog\" | \"mouse\";\n * pipe(\n * data,\n * isIncludedIn([\"cat\", \"dog\"] as const),\n * ); // => true (typed \"cat\" | \"dog\");\n * @dataLast\n * @category Guard\n */\nexport function isIncludedIn<T, S extends IterableContainer<T>>(\n container: IsNarrowable<T, S> extends true ? S : never,\n): (data: T) => data is S[number];\nexport function isIncludedIn<T, S extends T>(\n container: IterableContainer<S>,\n): (data: T) => boolean;\n\nexport function isIncludedIn(\n dataOrContainer: unknown,\n container?: ReadonlyArray<unknown>,\n): unknown {\n if (container === undefined) {\n // === dataLast ===\n // We don't use curry here because we can optimize the dataLast case by\n // memoizing a set and accessing it in O(1) time instead of scanning the\n // array **each time** (O(n)) each time.\n const asSet = new Set(dataOrContainer as ReadonlyArray<unknown>);\n return (data: unknown) => asSet.has(data);\n }\n\n // === dataFirst ===\n return container.includes(dataOrContainer);\n}\n"],"mappings":"mEAyIA,SAAgB,EACd,EACA,EACS,CACT,GAAI,IAAc,IAAA,GAAW,CAK3B,IAAM,EAAQ,IAAI,IAAI,CAAyC,EAC/D,MAAQ,IAAkB,EAAM,IAAI,CAAI,CAC1C,CAGA,OAAO,EAAU,SAAS,CAAe,CAC3C"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-included-in.js","names":[],"sources":["../src/is-included-in.ts"],"sourcesContent":["import type { IsLiteral, IsUnion } from 'type-fest';\nimport type { IterableContainer } from './internal/types/iterable-container';\n\n/**\n * A \"constant\" tuple is a type that has a single runtime value that can fulfil\n * it. This means that it doesn't have any variadic/rest/spread/array parts, and\n * that all it's values are singular (non-union) literals.\n *\n * We use this type to allow narrowing when checking against a set of values\n * defined as a const.\n *\n * @example\n * type T1 = IsConstantTuple<[\"cat\", \"dog\", 3, true]>; // => true;\n * type T2 = IsConstantTuple<[\"cat\" | \"dog\"]>; // false;\n * type T2 = IsConstantTuple<[\"cat\", ...\"cat\"[]]>; // false;\n */\ntype IsConstantTuple<T extends IterableContainer> = T extends readonly []\n ? true\n : T extends readonly [infer Head, ...infer Rest]\n ? IsUnion<Head> extends true\n ? false\n : IsConstantTuple<Rest>\n : false;\n\n/**\n * There is no way to tell Typescript to only narrow the \"accepted\" side of a\n * type-predicate and so in many cases the negated side is also affected, this\n * results in over-narrowing in many cases, breaking typing. For this reason we\n * only want to use the type-predicate variant of `isIncludedIn` when we can\n * assume the result represents the expected types (closely enough). This is not\n * and ideal solution and we will still generate wrong types in some cases (see\n * tests), but it reduces the surface of this problem significantly, while still\n * keeping the utility of `isIncludedIn` for the common cases.\n *\n * TL;DR - The types are narrowable when: T is literal and S is a pure tuple, or\n * when T isn't a literal, but S is.\n *\n * @example\n * const data = 1 as 1 | 2 | 3;\n * const container = [] as (1 | 2)[];\n * if (isIncludedIn(data, container)) {\n * ... it makes sense to narrow data to `1 | 2` as the value `3` is not part\n * ... of the typing of container, so will never result in being true.\n * } else {\n * ... but it doesn't make sense to narrow the value to 3 here, because 1\n * ... and 2 are still valid values for data, when container doesn't include\n * ... them **at runtime**.\n * ... Typescript narrows the _rejected_ branch based on how it narrowed the\n * ... _accepted_ clause, and we can't control that; because our input type\n * ... is `1 | 2 | 3` and the accepted side is `1 | 2`, the rejected side is\n * ... typed `Exclude<1 | 2 | 3, 1 | 2>`, which is `3`.\n * }\n * }\n */\ntype IsNarrowable<T, S extends IterableContainer<T>>\n = IsLiteral<T> extends true\n ? // When T is literal (i.g. it isn't a primitive type like `string` or\n // `number`) then the criteria for narrowing is that the container is a\n // \"pure\" tuple because we *assume* that S represents a constant set of\n // values, and that it's typing also represents it's runtime content 1-\n // for-1. If S isn't a pure tuple it means we can't tell from the typing\n // which of it's values are actually present in runtime so can't use them\n // to narrow correctly.\n IsConstantTuple<S>\n : // When T isn't a literal type but the items in S are we can narrow the\n // type because it won't affect the negated side (`Exclude<number, 3>`\n // is still `number`).\n IsLiteral<S[number]>;\n\n/**\n * Checks if the item is included in the container. This is a wrapper around\n * `Array.prototype.includes` and `Set.prototype.has` and thus relies on the\n * same equality checks that those functions do (which is reference equality,\n * e.g. `===`). In some cases the input's type is also narrowed to the\n * container's item types.\n *\n * Notice that unlike most functions, this function takes a generic item as it's\n * data and **an array** as it's parameter.\n *\n * @param data - The item that is checked.\n * @param container - The items that are checked against.\n * @returns `true` if the item is in the container, or `false` otherwise. In\n * cases the type of `data` is also narrowed down.\n * @signature\n * isIncludedIn(data, container);\n * @example\n * isIncludedIn(2, [1, 2, 3]); // => true\n * isIncludedIn(4, [1, 2, 3]); // => false\n *\n * const data = \"cat\" as \"cat\" | \"dog\" | \"mouse\";\n * isIncludedIn(data, [\"cat\", \"dog\"] as const); // true (typed \"cat\" | \"dog\");\n * @dataFirst\n * @category Guard\n */\nexport function isIncludedIn<T, S extends IterableContainer<T>>(\n data: T,\n container: IsNarrowable<T, S> extends true ? S : never,\n): data is S[number];\nexport function isIncludedIn<T, S extends T>(\n data: T,\n container: IterableContainer<S>,\n): boolean;\n\n/**\n * Checks if the item is included in the container. This is a wrapper around\n * `Array.prototype.includes` and `Set.prototype.has` and thus relies on the\n * same equality checks that those functions do (which is reference equality,\n * e.g. `===`). In some cases the input's type is also narrowed to the\n * container's item types.\n *\n * Notice that unlike most functions, this function takes a generic item as it's\n * data and **an array** as it's parameter.\n *\n * @param container - The items that are checked against.\n * @returns `true` if the item is in the container, or `false` otherwise. In\n * cases the type of `data` is also narrowed down.\n * @signature\n * isIncludedIn(container)(data);\n * @example\n * pipe(2, isIncludedIn([1, 2, 3])); // => true\n * pipe(4, isIncludedIn([1, 2, 3])); // => false\n *\n * const data = \"cat\" as \"cat\" | \"dog\" | \"mouse\";\n * pipe(\n * data,\n * isIncludedIn([\"cat\", \"dog\"] as const),\n * ); // => true (typed \"cat\" | \"dog\");\n * @dataLast\n * @category Guard\n */\nexport function isIncludedIn<T, S extends IterableContainer<T>>(\n container: IsNarrowable<T, S> extends true ? S : never,\n): (data: T) => data is S[number];\nexport function isIncludedIn<T, S extends T>(\n container: IterableContainer<S>,\n): (data: T) => boolean;\n\nexport function isIncludedIn(\n dataOrContainer: unknown,\n container?: ReadonlyArray<unknown>,\n): unknown {\n if (container === undefined) {\n // === dataLast ===\n // We don't use curry here because we can optimize the dataLast case by\n // memoizing a set and accessing it in O(1) time instead of scanning the\n // array **each time** (O(n)) each time.\n const asSet = new Set(dataOrContainer as ReadonlyArray<unknown>);\n return (data: unknown) => asSet.has(data);\n }\n\n // === dataFirst ===\n return container.includes(dataOrContainer);\n}\n"],"mappings":"AAyIA,SAAgB,EACd,EACA,EACS,CACT,GAAI,IAAc,IAAA,GAAW,CAK3B,IAAM,EAAQ,IAAI,IAAI,EAA0C,CAChE,MAAQ,IAAkB,EAAM,IAAI,EAAK,CAI3C,OAAO,EAAU,SAAS,EAAgB"}
1
+ {"version":3,"file":"is-included-in.js","names":[],"sources":["../src/is-included-in.ts"],"sourcesContent":["import type { IsLiteral, IsUnion } from 'type-fest';\nimport type { IterableContainer } from './internal/types/iterable-container';\n\n/**\n * A \"constant\" tuple is a type that has a single runtime value that can fulfil\n * it. This means that it doesn't have any variadic/rest/spread/array parts, and\n * that all it's values are singular (non-union) literals.\n *\n * We use this type to allow narrowing when checking against a set of values\n * defined as a const.\n *\n * @example\n * type T1 = IsConstantTuple<[\"cat\", \"dog\", 3, true]>; // => true;\n * type T2 = IsConstantTuple<[\"cat\" | \"dog\"]>; // false;\n * type T2 = IsConstantTuple<[\"cat\", ...\"cat\"[]]>; // false;\n */\ntype IsConstantTuple<T extends IterableContainer> = T extends readonly []\n ? true\n : T extends readonly [infer Head, ...infer Rest]\n ? IsUnion<Head> extends true\n ? false\n : IsConstantTuple<Rest>\n : false;\n\n/**\n * There is no way to tell Typescript to only narrow the \"accepted\" side of a\n * type-predicate and so in many cases the negated side is also affected, this\n * results in over-narrowing in many cases, breaking typing. For this reason we\n * only want to use the type-predicate variant of `isIncludedIn` when we can\n * assume the result represents the expected types (closely enough). This is not\n * and ideal solution and we will still generate wrong types in some cases (see\n * tests), but it reduces the surface of this problem significantly, while still\n * keeping the utility of `isIncludedIn` for the common cases.\n *\n * TL;DR - The types are narrowable when: T is literal and S is a pure tuple, or\n * when T isn't a literal, but S is.\n *\n * @example\n * const data = 1 as 1 | 2 | 3;\n * const container = [] as (1 | 2)[];\n * if (isIncludedIn(data, container)) {\n * ... it makes sense to narrow data to `1 | 2` as the value `3` is not part\n * ... of the typing of container, so will never result in being true.\n * } else {\n * ... but it doesn't make sense to narrow the value to 3 here, because 1\n * ... and 2 are still valid values for data, when container doesn't include\n * ... them **at runtime**.\n * ... Typescript narrows the _rejected_ branch based on how it narrowed the\n * ... _accepted_ clause, and we can't control that; because our input type\n * ... is `1 | 2 | 3` and the accepted side is `1 | 2`, the rejected side is\n * ... typed `Exclude<1 | 2 | 3, 1 | 2>`, which is `3`.\n * }\n * }\n */\ntype IsNarrowable<T, S extends IterableContainer<T>>\n = IsLiteral<T> extends true\n ? // When T is literal (i.g. it isn't a primitive type like `string` or\n // `number`) then the criteria for narrowing is that the container is a\n // \"pure\" tuple because we *assume* that S represents a constant set of\n // values, and that it's typing also represents it's runtime content 1-\n // for-1. If S isn't a pure tuple it means we can't tell from the typing\n // which of it's values are actually present in runtime so can't use them\n // to narrow correctly.\n IsConstantTuple<S>\n : // When T isn't a literal type but the items in S are we can narrow the\n // type because it won't affect the negated side (`Exclude<number, 3>`\n // is still `number`).\n IsLiteral<S[number]>;\n\n/**\n * Checks if the item is included in the container. This is a wrapper around\n * `Array.prototype.includes` and `Set.prototype.has` and thus relies on the\n * same equality checks that those functions do (which is reference equality,\n * e.g. `===`). In some cases the input's type is also narrowed to the\n * container's item types.\n *\n * Notice that unlike most functions, this function takes a generic item as it's\n * data and **an array** as it's parameter.\n *\n * @param data - The item that is checked.\n * @param container - The items that are checked against.\n * @returns `true` if the item is in the container, or `false` otherwise. In\n * cases the type of `data` is also narrowed down.\n * @signature\n * isIncludedIn(data, container);\n * @example\n * isIncludedIn(2, [1, 2, 3]); // => true\n * isIncludedIn(4, [1, 2, 3]); // => false\n *\n * const data = \"cat\" as \"cat\" | \"dog\" | \"mouse\";\n * isIncludedIn(data, [\"cat\", \"dog\"] as const); // true (typed \"cat\" | \"dog\");\n * @dataFirst\n * @category Guard\n */\nexport function isIncludedIn<T, S extends IterableContainer<T>>(\n data: T,\n container: IsNarrowable<T, S> extends true ? S : never,\n): data is S[number];\nexport function isIncludedIn<T, S extends T>(\n data: T,\n container: IterableContainer<S>,\n): boolean;\n\n/**\n * Checks if the item is included in the container. This is a wrapper around\n * `Array.prototype.includes` and `Set.prototype.has` and thus relies on the\n * same equality checks that those functions do (which is reference equality,\n * e.g. `===`). In some cases the input's type is also narrowed to the\n * container's item types.\n *\n * Notice that unlike most functions, this function takes a generic item as it's\n * data and **an array** as it's parameter.\n *\n * @param container - The items that are checked against.\n * @returns `true` if the item is in the container, or `false` otherwise. In\n * cases the type of `data` is also narrowed down.\n * @signature\n * isIncludedIn(container)(data);\n * @example\n * pipe(2, isIncludedIn([1, 2, 3])); // => true\n * pipe(4, isIncludedIn([1, 2, 3])); // => false\n *\n * const data = \"cat\" as \"cat\" | \"dog\" | \"mouse\";\n * pipe(\n * data,\n * isIncludedIn([\"cat\", \"dog\"] as const),\n * ); // => true (typed \"cat\" | \"dog\");\n * @dataLast\n * @category Guard\n */\nexport function isIncludedIn<T, S extends IterableContainer<T>>(\n container: IsNarrowable<T, S> extends true ? S : never,\n): (data: T) => data is S[number];\nexport function isIncludedIn<T, S extends T>(\n container: IterableContainer<S>,\n): (data: T) => boolean;\n\nexport function isIncludedIn(\n dataOrContainer: unknown,\n container?: ReadonlyArray<unknown>,\n): unknown {\n if (container === undefined) {\n // === dataLast ===\n // We don't use curry here because we can optimize the dataLast case by\n // memoizing a set and accessing it in O(1) time instead of scanning the\n // array **each time** (O(n)) each time.\n const asSet = new Set(dataOrContainer as ReadonlyArray<unknown>);\n return (data: unknown) => asSet.has(data);\n }\n\n // === dataFirst ===\n return container.includes(dataOrContainer);\n}\n"],"mappings":"AAyIA,SAAgB,EACd,EACA,EACS,CACT,GAAI,IAAc,IAAA,GAAW,CAK3B,IAAM,EAAQ,IAAI,IAAI,CAAyC,EAC/D,MAAQ,IAAkB,EAAM,IAAI,CAAI,CAC1C,CAGA,OAAO,EAAU,SAAS,CAAe,CAC3C"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-non-null.cjs","names":[],"sources":["../src/is-non-null.ts"],"sourcesContent":["/**\n * A function that checks if the passed parameter is not `null` and narrows its type accordingly.\n * Notice that `undefined` is not null!\n *\n * @param data - The variable to check.\n * @returns True if the passed input is defined, false otherwise.\n * @signature\n * isNonNull(data)\n * @example\n * isNonNull('string') //=> true\n * isNonNull(null) //=> false\n * isNonNull(undefined) //=> true\n * @category Guard\n */\nexport function isNonNull<T>(data: T | null): data is T {\n return data !== null;\n}\n"],"mappings":"mEAcA,SAAgB,EAAa,EAA2B,CACtD,OAAO,IAAS"}
1
+ {"version":3,"file":"is-non-null.cjs","names":[],"sources":["../src/is-non-null.ts"],"sourcesContent":["/**\n * A function that checks if the passed parameter is not `null` and narrows its type accordingly.\n * Notice that `undefined` is not null!\n *\n * @param data - The variable to check.\n * @returns True if the passed input is defined, false otherwise.\n * @signature\n * isNonNull(data)\n * @example\n * isNonNull('string') //=> true\n * isNonNull(null) //=> false\n * isNonNull(undefined) //=> true\n * @category Guard\n */\nexport function isNonNull<T>(data: T | null): data is T {\n return data !== null;\n}\n"],"mappings":"mEAcA,SAAgB,EAAa,EAA2B,CACtD,OAAO,IAAS,IAClB"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-non-null.js","names":[],"sources":["../src/is-non-null.ts"],"sourcesContent":["/**\n * A function that checks if the passed parameter is not `null` and narrows its type accordingly.\n * Notice that `undefined` is not null!\n *\n * @param data - The variable to check.\n * @returns True if the passed input is defined, false otherwise.\n * @signature\n * isNonNull(data)\n * @example\n * isNonNull('string') //=> true\n * isNonNull(null) //=> false\n * isNonNull(undefined) //=> true\n * @category Guard\n */\nexport function isNonNull<T>(data: T | null): data is T {\n return data !== null;\n}\n"],"mappings":"AAcA,SAAgB,EAAa,EAA2B,CACtD,OAAO,IAAS"}
1
+ {"version":3,"file":"is-non-null.js","names":[],"sources":["../src/is-non-null.ts"],"sourcesContent":["/**\n * A function that checks if the passed parameter is not `null` and narrows its type accordingly.\n * Notice that `undefined` is not null!\n *\n * @param data - The variable to check.\n * @returns True if the passed input is defined, false otherwise.\n * @signature\n * isNonNull(data)\n * @example\n * isNonNull('string') //=> true\n * isNonNull(null) //=> false\n * isNonNull(undefined) //=> true\n * @category Guard\n */\nexport function isNonNull<T>(data: T | null): data is T {\n return data !== null;\n}\n"],"mappings":"AAcA,SAAgB,EAAa,EAA2B,CACtD,OAAO,IAAS,IAClB"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-non-nullish.cjs","names":[],"sources":["../src/is-non-nullish.ts"],"sourcesContent":["/**\n * A function that checks if the passed parameter is defined *AND* isn't `null`\n * and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is defined and isn't `null`, false\n * otherwise.\n * @signature\n * isNonNullish(data)\n * @example\n * isNonNullish('string') //=> true\n * isNonNullish(null) //=> false\n * isNonNullish(undefined) //=> false\n * @category Guard\n */\nexport function isNonNullish<T>(data: T): data is NonNullable<T> {\n return data !== undefined && data !== null;\n}\n"],"mappings":"mEAeA,SAAgB,EAAgB,EAAiC,CAC/D,OAAO,GAA+B"}
1
+ {"version":3,"file":"is-non-nullish.cjs","names":[],"sources":["../src/is-non-nullish.ts"],"sourcesContent":["/**\n * A function that checks if the passed parameter is defined *AND* isn't `null`\n * and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is defined and isn't `null`, false\n * otherwise.\n * @signature\n * isNonNullish(data)\n * @example\n * isNonNullish('string') //=> true\n * isNonNullish(null) //=> false\n * isNonNullish(undefined) //=> false\n * @category Guard\n */\nexport function isNonNullish<T>(data: T): data is NonNullable<T> {\n return data !== undefined && data !== null;\n}\n"],"mappings":"mEAeA,SAAgB,EAAgB,EAAiC,CAC/D,OAAO,GAA+B,IACxC"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-non-nullish.js","names":[],"sources":["../src/is-non-nullish.ts"],"sourcesContent":["/**\n * A function that checks if the passed parameter is defined *AND* isn't `null`\n * and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is defined and isn't `null`, false\n * otherwise.\n * @signature\n * isNonNullish(data)\n * @example\n * isNonNullish('string') //=> true\n * isNonNullish(null) //=> false\n * isNonNullish(undefined) //=> false\n * @category Guard\n */\nexport function isNonNullish<T>(data: T): data is NonNullable<T> {\n return data !== undefined && data !== null;\n}\n"],"mappings":"AAeA,SAAgB,EAAgB,EAAiC,CAC/D,OAAO,GAA+B"}
1
+ {"version":3,"file":"is-non-nullish.js","names":[],"sources":["../src/is-non-nullish.ts"],"sourcesContent":["/**\n * A function that checks if the passed parameter is defined *AND* isn't `null`\n * and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is defined and isn't `null`, false\n * otherwise.\n * @signature\n * isNonNullish(data)\n * @example\n * isNonNullish('string') //=> true\n * isNonNullish(null) //=> false\n * isNonNullish(undefined) //=> false\n * @category Guard\n */\nexport function isNonNullish<T>(data: T): data is NonNullable<T> {\n return data !== undefined && data !== null;\n}\n"],"mappings":"AAeA,SAAgB,EAAgB,EAAiC,CAC/D,OAAO,GAA+B,IACxC"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-not.cjs","names":[],"sources":["../src/is-not.ts"],"sourcesContent":["/**\n * A function that takes a guard function as predicate and returns a guard that negates it.\n *\n * @param predicate - The guard function to negate.\n * @returns Function A guard function.\n * @signature\n * isNot(isTruthy)(data)\n * @example\n * isNot(isTruthy)(false) //=> true\n * isNot(isTruthy)(true) //=> false\n * @dataLast\n * @category Guard\n */\nexport function isNot<T, S extends T>(\n predicate: (data: T) => data is S,\n): (data: T) => data is Exclude<T, S>;\nexport function isNot<T>(predicate: (data: T) => boolean): (data: T) => boolean;\n\nexport function isNot<T>(predicate: (data: T) => boolean) {\n return (data: T): boolean => !predicate(data);\n}\n"],"mappings":"mEAkBA,SAAgB,EAAS,EAAiC,CACxD,MAAQ,IAAqB,CAAC,EAAU,EAAK"}
1
+ {"version":3,"file":"is-not.cjs","names":[],"sources":["../src/is-not.ts"],"sourcesContent":["/**\n * A function that takes a guard function as predicate and returns a guard that negates it.\n *\n * @param predicate - The guard function to negate.\n * @returns Function A guard function.\n * @signature\n * isNot(isTruthy)(data)\n * @example\n * isNot(isTruthy)(false) //=> true\n * isNot(isTruthy)(true) //=> false\n * @dataLast\n * @category Guard\n */\nexport function isNot<T, S extends T>(\n predicate: (data: T) => data is S,\n): (data: T) => data is Exclude<T, S>;\nexport function isNot<T>(predicate: (data: T) => boolean): (data: T) => boolean;\n\nexport function isNot<T>(predicate: (data: T) => boolean) {\n return (data: T): boolean => !predicate(data);\n}\n"],"mappings":"mEAkBA,SAAgB,EAAS,EAAiC,CACxD,MAAQ,IAAqB,CAAC,EAAU,CAAI,CAC9C"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-not.js","names":[],"sources":["../src/is-not.ts"],"sourcesContent":["/**\n * A function that takes a guard function as predicate and returns a guard that negates it.\n *\n * @param predicate - The guard function to negate.\n * @returns Function A guard function.\n * @signature\n * isNot(isTruthy)(data)\n * @example\n * isNot(isTruthy)(false) //=> true\n * isNot(isTruthy)(true) //=> false\n * @dataLast\n * @category Guard\n */\nexport function isNot<T, S extends T>(\n predicate: (data: T) => data is S,\n): (data: T) => data is Exclude<T, S>;\nexport function isNot<T>(predicate: (data: T) => boolean): (data: T) => boolean;\n\nexport function isNot<T>(predicate: (data: T) => boolean) {\n return (data: T): boolean => !predicate(data);\n}\n"],"mappings":"AAkBA,SAAgB,EAAS,EAAiC,CACxD,MAAQ,IAAqB,CAAC,EAAU,EAAK"}
1
+ {"version":3,"file":"is-not.js","names":[],"sources":["../src/is-not.ts"],"sourcesContent":["/**\n * A function that takes a guard function as predicate and returns a guard that negates it.\n *\n * @param predicate - The guard function to negate.\n * @returns Function A guard function.\n * @signature\n * isNot(isTruthy)(data)\n * @example\n * isNot(isTruthy)(false) //=> true\n * isNot(isTruthy)(true) //=> false\n * @dataLast\n * @category Guard\n */\nexport function isNot<T, S extends T>(\n predicate: (data: T) => data is S,\n): (data: T) => data is Exclude<T, S>;\nexport function isNot<T>(predicate: (data: T) => boolean): (data: T) => boolean;\n\nexport function isNot<T>(predicate: (data: T) => boolean) {\n return (data: T): boolean => !predicate(data);\n}\n"],"mappings":"AAkBA,SAAgB,EAAS,EAAiC,CACxD,MAAQ,IAAqB,CAAC,EAAU,CAAI,CAC9C"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-nullish.cjs","names":[],"sources":["../src/is-nullish.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * A function that checks if the passed parameter is either `null` or\n * `undefined` and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is either `null` or `undefined`, false\n * otherwise.\n * @signature\n * isNullish(data)\n * @example\n * isNullish(undefined) //=> true\n * isNullish(null) //=> true\n * isNullish('somethingElse') //=> false\n * @category Guard\n */\nexport function isNullish<T>(\n data: T | null | undefined,\n): data is NarrowedTo<T, null | undefined> {\n return data === null || data === undefined;\n}\n"],"mappings":"mEAiBA,SAAgB,EACd,EACyC,CACzC,OAAO,GAAS"}
1
+ {"version":3,"file":"is-nullish.cjs","names":[],"sources":["../src/is-nullish.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * A function that checks if the passed parameter is either `null` or\n * `undefined` and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is either `null` or `undefined`, false\n * otherwise.\n * @signature\n * isNullish(data)\n * @example\n * isNullish(undefined) //=> true\n * isNullish(null) //=> true\n * isNullish('somethingElse') //=> false\n * @category Guard\n */\nexport function isNullish<T>(\n data: T | null | undefined,\n): data is NarrowedTo<T, null | undefined> {\n return data === null || data === undefined;\n}\n"],"mappings":"mEAiBA,SAAgB,EACd,EACyC,CACzC,OAAO,GAAS,IAClB"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-nullish.js","names":[],"sources":["../src/is-nullish.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * A function that checks if the passed parameter is either `null` or\n * `undefined` and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is either `null` or `undefined`, false\n * otherwise.\n * @signature\n * isNullish(data)\n * @example\n * isNullish(undefined) //=> true\n * isNullish(null) //=> true\n * isNullish('somethingElse') //=> false\n * @category Guard\n */\nexport function isNullish<T>(\n data: T | null | undefined,\n): data is NarrowedTo<T, null | undefined> {\n return data === null || data === undefined;\n}\n"],"mappings":"AAiBA,SAAgB,EACd,EACyC,CACzC,OAAO,GAAS"}
1
+ {"version":3,"file":"is-nullish.js","names":[],"sources":["../src/is-nullish.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * A function that checks if the passed parameter is either `null` or\n * `undefined` and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is either `null` or `undefined`, false\n * otherwise.\n * @signature\n * isNullish(data)\n * @example\n * isNullish(undefined) //=> true\n * isNullish(null) //=> true\n * isNullish('somethingElse') //=> false\n * @category Guard\n */\nexport function isNullish<T>(\n data: T | null | undefined,\n): data is NarrowedTo<T, null | undefined> {\n return data === null || data === undefined;\n}\n"],"mappings":"AAiBA,SAAgB,EACd,EACyC,CACzC,OAAO,GAAS,IAClB"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-number.cjs","names":[],"sources":["../src/is-number.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * A function that checks if the passed parameter is a number and narrows its\n * type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is a number, false otherwise.\n * @signature\n * isNumber(data)\n * @example\n * isNumber(1); // => true\n * isNumber(1n); // => false\n * isNumber('notANumber'); // => false\n * @category Guard\n */\nexport function isNumber<T>(data: T | number): data is NarrowedTo<T, number> {\n return typeof data === 'number' && !Number.isNaN(data);\n}\n"],"mappings":"mEAgBA,SAAgB,EAAY,EAAiD,CAC3E,OAAO,OAAO,GAAS,UAAY,CAAC,OAAO,MAAM,EAAK"}
1
+ {"version":3,"file":"is-number.cjs","names":[],"sources":["../src/is-number.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * A function that checks if the passed parameter is a number and narrows its\n * type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is a number, false otherwise.\n * @signature\n * isNumber(data)\n * @example\n * isNumber(1); // => true\n * isNumber(1n); // => false\n * isNumber('notANumber'); // => false\n * @category Guard\n */\nexport function isNumber<T>(data: T | number): data is NarrowedTo<T, number> {\n return typeof data === 'number' && !Number.isNaN(data);\n}\n"],"mappings":"mEAgBA,SAAgB,EAAY,EAAiD,CAC3E,OAAO,OAAO,GAAS,UAAY,CAAC,OAAO,MAAM,CAAI,CACvD"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-number.js","names":[],"sources":["../src/is-number.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * A function that checks if the passed parameter is a number and narrows its\n * type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is a number, false otherwise.\n * @signature\n * isNumber(data)\n * @example\n * isNumber(1); // => true\n * isNumber(1n); // => false\n * isNumber('notANumber'); // => false\n * @category Guard\n */\nexport function isNumber<T>(data: T | number): data is NarrowedTo<T, number> {\n return typeof data === 'number' && !Number.isNaN(data);\n}\n"],"mappings":"AAgBA,SAAgB,EAAY,EAAiD,CAC3E,OAAO,OAAO,GAAS,UAAY,CAAC,OAAO,MAAM,EAAK"}
1
+ {"version":3,"file":"is-number.js","names":[],"sources":["../src/is-number.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * A function that checks if the passed parameter is a number and narrows its\n * type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is a number, false otherwise.\n * @signature\n * isNumber(data)\n * @example\n * isNumber(1); // => true\n * isNumber(1n); // => false\n * isNumber('notANumber'); // => false\n * @category Guard\n */\nexport function isNumber<T>(data: T | number): data is NarrowedTo<T, number> {\n return typeof data === 'number' && !Number.isNaN(data);\n}\n"],"mappings":"AAgBA,SAAgB,EAAY,EAAiD,CAC3E,OAAO,OAAO,GAAS,UAAY,CAAC,OAAO,MAAM,CAAI,CACvD"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-object-type.cjs","names":[],"sources":["../src/is-object-type.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * Checks if the given parameter is of type `\"object\"` via `typeof`, excluding `null`.\n *\n * It's important to note that in JavaScript, many entities are considered objects, like Arrays, Classes, RegExps, Maps, Sets, Dates, URLs, Promise, Errors, and more. Although technically an object too, `null` is not considered an object by this function, so that its easier to narrow nullables.\n *\n * For a more specific check that is limited to plain objects (simple struct/shape/record-like objects), consider using `isPlainObject` instead. For a simpler check that only removes `null` from the type prefer `isNonNull` or `isDefined`.\n *\n * @param data - The variable to be checked for being an object type.\n * @returns The input type, narrowed to only objects.\n * @signature\n * isObjectType(data)\n * @example\n * // true\n * isObjectType({}) //=> true\n * isObjectType([]) //=> true\n * isObjectType(Promise.resolve(\"something\")) //=> true\n * isObjectType(new Date()) //=> true\n * isObjectType(new Error(\"error\")) //=> true\n *\n * // false\n * isObjectType('somethingElse') //=> false\n * isObjectType(null) //=> false\n * @dataFirst\n * @category Guard\n */\nexport function isObjectType<T>(\n data: T | object,\n): data is NarrowedTo<T, object> {\n return typeof data === 'object' && data !== null;\n}\n"],"mappings":"mEA2BA,SAAgB,EACd,EAC+B,CAC/B,OAAO,OAAO,GAAS,YAAY"}
1
+ {"version":3,"file":"is-object-type.cjs","names":[],"sources":["../src/is-object-type.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * Checks if the given parameter is of type `\"object\"` via `typeof`, excluding `null`.\n *\n * It's important to note that in JavaScript, many entities are considered objects, like Arrays, Classes, RegExps, Maps, Sets, Dates, URLs, Promise, Errors, and more. Although technically an object too, `null` is not considered an object by this function, so that its easier to narrow nullables.\n *\n * For a more specific check that is limited to plain objects (simple struct/shape/record-like objects), consider using `isPlainObject` instead. For a simpler check that only removes `null` from the type prefer `isNonNull` or `isDefined`.\n *\n * @param data - The variable to be checked for being an object type.\n * @returns The input type, narrowed to only objects.\n * @signature\n * isObjectType(data)\n * @example\n * // true\n * isObjectType({}) //=> true\n * isObjectType([]) //=> true\n * isObjectType(Promise.resolve(\"something\")) //=> true\n * isObjectType(new Date()) //=> true\n * isObjectType(new Error(\"error\")) //=> true\n *\n * // false\n * isObjectType('somethingElse') //=> false\n * isObjectType(null) //=> false\n * @dataFirst\n * @category Guard\n */\nexport function isObjectType<T>(\n data: T | object,\n): data is NarrowedTo<T, object> {\n return typeof data === 'object' && data !== null;\n}\n"],"mappings":"mEA2BA,SAAgB,EACd,EAC+B,CAC/B,OAAO,OAAO,GAAS,YAAY,CACrC"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-object-type.js","names":[],"sources":["../src/is-object-type.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * Checks if the given parameter is of type `\"object\"` via `typeof`, excluding `null`.\n *\n * It's important to note that in JavaScript, many entities are considered objects, like Arrays, Classes, RegExps, Maps, Sets, Dates, URLs, Promise, Errors, and more. Although technically an object too, `null` is not considered an object by this function, so that its easier to narrow nullables.\n *\n * For a more specific check that is limited to plain objects (simple struct/shape/record-like objects), consider using `isPlainObject` instead. For a simpler check that only removes `null` from the type prefer `isNonNull` or `isDefined`.\n *\n * @param data - The variable to be checked for being an object type.\n * @returns The input type, narrowed to only objects.\n * @signature\n * isObjectType(data)\n * @example\n * // true\n * isObjectType({}) //=> true\n * isObjectType([]) //=> true\n * isObjectType(Promise.resolve(\"something\")) //=> true\n * isObjectType(new Date()) //=> true\n * isObjectType(new Error(\"error\")) //=> true\n *\n * // false\n * isObjectType('somethingElse') //=> false\n * isObjectType(null) //=> false\n * @dataFirst\n * @category Guard\n */\nexport function isObjectType<T>(\n data: T | object,\n): data is NarrowedTo<T, object> {\n return typeof data === 'object' && data !== null;\n}\n"],"mappings":"AA2BA,SAAgB,EACd,EAC+B,CAC/B,OAAO,OAAO,GAAS,YAAY"}
1
+ {"version":3,"file":"is-object-type.js","names":[],"sources":["../src/is-object-type.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * Checks if the given parameter is of type `\"object\"` via `typeof`, excluding `null`.\n *\n * It's important to note that in JavaScript, many entities are considered objects, like Arrays, Classes, RegExps, Maps, Sets, Dates, URLs, Promise, Errors, and more. Although technically an object too, `null` is not considered an object by this function, so that its easier to narrow nullables.\n *\n * For a more specific check that is limited to plain objects (simple struct/shape/record-like objects), consider using `isPlainObject` instead. For a simpler check that only removes `null` from the type prefer `isNonNull` or `isDefined`.\n *\n * @param data - The variable to be checked for being an object type.\n * @returns The input type, narrowed to only objects.\n * @signature\n * isObjectType(data)\n * @example\n * // true\n * isObjectType({}) //=> true\n * isObjectType([]) //=> true\n * isObjectType(Promise.resolve(\"something\")) //=> true\n * isObjectType(new Date()) //=> true\n * isObjectType(new Error(\"error\")) //=> true\n *\n * // false\n * isObjectType('somethingElse') //=> false\n * isObjectType(null) //=> false\n * @dataFirst\n * @category Guard\n */\nexport function isObjectType<T>(\n data: T | object,\n): data is NarrowedTo<T, object> {\n return typeof data === 'object' && data !== null;\n}\n"],"mappings":"AA2BA,SAAgB,EACd,EAC+B,CAC/B,OAAO,OAAO,GAAS,YAAY,CACrC"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-plain-object.cjs","names":[],"sources":["../src/is-plain-object.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * Checks if `data` is a \"plain\" object. A plain object is defined as an object with string keys and values of any type, including primitives, other objects, functions, classes, etc (aka struct/shape/record/simple). Technically, a plain object is one whose prototype is either `Object.prototype` or `null`, ensuring it does not inherit properties or methods from other object types.\n *\n * This function is narrower in scope than `isObjectType`, which accepts any entity considered an `\"object\"` by JavaScript's `typeof`.\n *\n * Note that Maps, Arrays, and Sets are not considered plain objects and would return `false`.\n *\n * @param data - The variable to check.\n * @returns The input type, narrowed to only plain objects.\n * @signature\n * isPlainObject(data)\n * @example\n * // true\n * isPlainObject({}) //=> true\n * isPlainObject({ a: 123 }) //=> true\n *\n * // false\n * isPlainObject([]) //=> false\n * isPlainObject(Promise.resolve(\"something\")) //=> false\n * isPlainObject(new Date()) //=> false\n * isPlainObject(new Error(\"error\")) //=> false\n * isPlainObject('somethingElse') //=> false\n * isPlainObject(null) //=> false\n * @category Guard\n */\nexport function isPlainObject<T>(\n data: Readonly<Record<PropertyKey, unknown>> | T,\n): data is NarrowedTo<T, Record<PropertyKey, unknown>> {\n if (typeof data !== 'object' || data == null) {\n return false;\n }\n\n const proto = Object.getPrototypeOf(data);\n return proto === null || proto === Object.prototype;\n}\n"],"mappings":"mEA2BA,SAAgB,EACd,EACqD,CACrD,GAAI,OAAO,GAAS,WAAY,EAC9B,MAAO,GAGT,IAAM,EAAQ,OAAO,eAAe,EAAK,CACzC,OAAO,IAAU,MAAQ,IAAU,OAAO"}
1
+ {"version":3,"file":"is-plain-object.cjs","names":[],"sources":["../src/is-plain-object.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * Checks if `data` is a \"plain\" object. A plain object is defined as an object with string keys and values of any type, including primitives, other objects, functions, classes, etc (aka struct/shape/record/simple). Technically, a plain object is one whose prototype is either `Object.prototype` or `null`, ensuring it does not inherit properties or methods from other object types.\n *\n * This function is narrower in scope than `isObjectType`, which accepts any entity considered an `\"object\"` by JavaScript's `typeof`.\n *\n * Note that Maps, Arrays, and Sets are not considered plain objects and would return `false`.\n *\n * @param data - The variable to check.\n * @returns The input type, narrowed to only plain objects.\n * @signature\n * isPlainObject(data)\n * @example\n * // true\n * isPlainObject({}) //=> true\n * isPlainObject({ a: 123 }) //=> true\n *\n * // false\n * isPlainObject([]) //=> false\n * isPlainObject(Promise.resolve(\"something\")) //=> false\n * isPlainObject(new Date()) //=> false\n * isPlainObject(new Error(\"error\")) //=> false\n * isPlainObject('somethingElse') //=> false\n * isPlainObject(null) //=> false\n * @category Guard\n */\nexport function isPlainObject<T>(\n data: Readonly<Record<PropertyKey, unknown>> | T,\n): data is NarrowedTo<T, Record<PropertyKey, unknown>> {\n if (typeof data !== 'object' || data == null) {\n return false;\n }\n\n const proto = Object.getPrototypeOf(data);\n return proto === null || proto === Object.prototype;\n}\n"],"mappings":"mEA2BA,SAAgB,EACd,EACqD,CACrD,GAAI,OAAO,GAAS,WAAY,EAC9B,MAAO,GAGT,IAAM,EAAQ,OAAO,eAAe,CAAI,EACxC,OAAO,IAAU,MAAQ,IAAU,OAAO,SAC5C"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-plain-object.js","names":[],"sources":["../src/is-plain-object.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * Checks if `data` is a \"plain\" object. A plain object is defined as an object with string keys and values of any type, including primitives, other objects, functions, classes, etc (aka struct/shape/record/simple). Technically, a plain object is one whose prototype is either `Object.prototype` or `null`, ensuring it does not inherit properties or methods from other object types.\n *\n * This function is narrower in scope than `isObjectType`, which accepts any entity considered an `\"object\"` by JavaScript's `typeof`.\n *\n * Note that Maps, Arrays, and Sets are not considered plain objects and would return `false`.\n *\n * @param data - The variable to check.\n * @returns The input type, narrowed to only plain objects.\n * @signature\n * isPlainObject(data)\n * @example\n * // true\n * isPlainObject({}) //=> true\n * isPlainObject({ a: 123 }) //=> true\n *\n * // false\n * isPlainObject([]) //=> false\n * isPlainObject(Promise.resolve(\"something\")) //=> false\n * isPlainObject(new Date()) //=> false\n * isPlainObject(new Error(\"error\")) //=> false\n * isPlainObject('somethingElse') //=> false\n * isPlainObject(null) //=> false\n * @category Guard\n */\nexport function isPlainObject<T>(\n data: Readonly<Record<PropertyKey, unknown>> | T,\n): data is NarrowedTo<T, Record<PropertyKey, unknown>> {\n if (typeof data !== 'object' || data == null) {\n return false;\n }\n\n const proto = Object.getPrototypeOf(data);\n return proto === null || proto === Object.prototype;\n}\n"],"mappings":"AA2BA,SAAgB,EACd,EACqD,CACrD,GAAI,OAAO,GAAS,WAAY,EAC9B,MAAO,GAGT,IAAM,EAAQ,OAAO,eAAe,EAAK,CACzC,OAAO,IAAU,MAAQ,IAAU,OAAO"}
1
+ {"version":3,"file":"is-plain-object.js","names":[],"sources":["../src/is-plain-object.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * Checks if `data` is a \"plain\" object. A plain object is defined as an object with string keys and values of any type, including primitives, other objects, functions, classes, etc (aka struct/shape/record/simple). Technically, a plain object is one whose prototype is either `Object.prototype` or `null`, ensuring it does not inherit properties or methods from other object types.\n *\n * This function is narrower in scope than `isObjectType`, which accepts any entity considered an `\"object\"` by JavaScript's `typeof`.\n *\n * Note that Maps, Arrays, and Sets are not considered plain objects and would return `false`.\n *\n * @param data - The variable to check.\n * @returns The input type, narrowed to only plain objects.\n * @signature\n * isPlainObject(data)\n * @example\n * // true\n * isPlainObject({}) //=> true\n * isPlainObject({ a: 123 }) //=> true\n *\n * // false\n * isPlainObject([]) //=> false\n * isPlainObject(Promise.resolve(\"something\")) //=> false\n * isPlainObject(new Date()) //=> false\n * isPlainObject(new Error(\"error\")) //=> false\n * isPlainObject('somethingElse') //=> false\n * isPlainObject(null) //=> false\n * @category Guard\n */\nexport function isPlainObject<T>(\n data: Readonly<Record<PropertyKey, unknown>> | T,\n): data is NarrowedTo<T, Record<PropertyKey, unknown>> {\n if (typeof data !== 'object' || data == null) {\n return false;\n }\n\n const proto = Object.getPrototypeOf(data);\n return proto === null || proto === Object.prototype;\n}\n"],"mappings":"AA2BA,SAAgB,EACd,EACqD,CACrD,GAAI,OAAO,GAAS,WAAY,EAC9B,MAAO,GAGT,IAAM,EAAQ,OAAO,eAAe,CAAI,EACxC,OAAO,IAAU,MAAQ,IAAU,OAAO,SAC5C"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-promise.cjs","names":[],"sources":["../src/is-promise.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * A function that checks if the passed parameter is a Promise and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is a Promise, false otherwise.\n * @signature\n * isPromise(data)\n * @example\n * isPromise(Promise.resolve(5)) //=> true\n * isPromise(Promise.reject(5)) //=> true\n * isPromise('somethingElse') //=> false\n * @category Guard\n */\nexport function isPromise<T>(\n data: Readonly<PromiseLike<unknown>> | T,\n): data is NarrowedTo<T, PromiseLike<unknown>> {\n return data instanceof Promise;\n}\n"],"mappings":"mEAeA,SAAgB,EACd,EAC6C,CAC7C,OAAO,aAAgB"}
1
+ {"version":3,"file":"is-promise.cjs","names":[],"sources":["../src/is-promise.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * A function that checks if the passed parameter is a Promise and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is a Promise, false otherwise.\n * @signature\n * isPromise(data)\n * @example\n * isPromise(Promise.resolve(5)) //=> true\n * isPromise(Promise.reject(5)) //=> true\n * isPromise('somethingElse') //=> false\n * @category Guard\n */\nexport function isPromise<T>(\n data: Readonly<PromiseLike<unknown>> | T,\n): data is NarrowedTo<T, PromiseLike<unknown>> {\n return data instanceof Promise;\n}\n"],"mappings":"mEAeA,SAAgB,EACd,EAC6C,CAC7C,OAAO,aAAgB,OACzB"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-promise.js","names":[],"sources":["../src/is-promise.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * A function that checks if the passed parameter is a Promise and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is a Promise, false otherwise.\n * @signature\n * isPromise(data)\n * @example\n * isPromise(Promise.resolve(5)) //=> true\n * isPromise(Promise.reject(5)) //=> true\n * isPromise('somethingElse') //=> false\n * @category Guard\n */\nexport function isPromise<T>(\n data: Readonly<PromiseLike<unknown>> | T,\n): data is NarrowedTo<T, PromiseLike<unknown>> {\n return data instanceof Promise;\n}\n"],"mappings":"AAeA,SAAgB,EACd,EAC6C,CAC7C,OAAO,aAAgB"}
1
+ {"version":3,"file":"is-promise.js","names":[],"sources":["../src/is-promise.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * A function that checks if the passed parameter is a Promise and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is a Promise, false otherwise.\n * @signature\n * isPromise(data)\n * @example\n * isPromise(Promise.resolve(5)) //=> true\n * isPromise(Promise.reject(5)) //=> true\n * isPromise('somethingElse') //=> false\n * @category Guard\n */\nexport function isPromise<T>(\n data: Readonly<PromiseLike<unknown>> | T,\n): data is NarrowedTo<T, PromiseLike<unknown>> {\n return data instanceof Promise;\n}\n"],"mappings":"AAeA,SAAgB,EACd,EAC6C,CAC7C,OAAO,aAAgB,OACzB"}
@@ -1,2 +1,2 @@
1
- Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require(`./curry.cjs`);function t(...t){return e.curry(n,t)}function n(e,t){if(e===t||Object.is(e,t))return!0;if(typeof e!=`object`||!e||typeof t!=`object`||!t)return!1;if(e instanceof Map&&t instanceof Map)return r(e,t);if(e instanceof Set&&t instanceof Set)return i(e,t);let n=Object.keys(e);if(n.length!==Object.keys(t).length)return!1;for(let r of n){if(!Object.hasOwn(t,r))return!1;let{[r]:n}=e,{[r]:i}=t;if(n!==i||!Object.is(n,i))return!1}return!0}function r(e,t){if(e.size!==t.size)return!1;for(let[n,r]of e){let e=t.get(n);if(r!==e||!Object.is(r,e))return!1}return!0}function i(e,t){if(e.size!==t.size)return!1;for(let n of e)if(!t.has(n))return!1;return!0}exports.isShallowEqual=t;
1
+ Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./curry.cjs");function t(...t){return e.curry(n,t)}function n(e,t){if(e===t||Object.is(e,t))return!0;if(typeof e!=`object`||!e||typeof t!=`object`||!t)return!1;if(e instanceof Map&&t instanceof Map)return r(e,t);if(e instanceof Set&&t instanceof Set)return i(e,t);let n=Object.keys(e);if(n.length!==Object.keys(t).length)return!1;for(let r of n){if(!Object.hasOwn(t,r))return!1;let{[r]:n}=e,{[r]:i}=t;if(n!==i||!Object.is(n,i))return!1}return!0}function r(e,t){if(e.size!==t.size)return!1;for(let[n,r]of e){let e=t.get(n);if(r!==e||!Object.is(r,e))return!1}return!0}function i(e,t){if(e.size!==t.size)return!1;for(let n of e)if(!t.has(n))return!1;return!0}exports.isShallowEqual=t;
2
2
  //# sourceMappingURL=is-shallow-equal.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"is-shallow-equal.cjs","names":["curry"],"sources":["../src/is-shallow-equal.ts"],"sourcesContent":["import { curry } from './curry';\n\n/**\n * Performs a *shallow structural* comparison between two values to determine if\n * they are equivalent. For primitive values this is equivalent to `===`, for\n * arrays a **strict equality** check would be performed on every item, in\n * order, and for objects props will be matched and checked for **strict\n * equality**; Unlike `isDeepEqual` where the function also *recurses* into each\n * item and value.\n *\n * !IMPORTANT: symbol properties of objects are not supported right now and\n * might result in unexpected behavior. Please open an issue in the Perkakas\n * github project if you need support for these types.\n *\n * !IMPORTANT: Promise, Date, and RegExp, are shallowly equal, even when they\n * are semantically different (e.g. resolved promises); but `isDeepEqual` does\n * compare the latter 2 semantically by-value.\n *\n * The result would be narrowed to the second value so that the function can be\n * used as a type guard.\n *\n * See:\n * - `isStrictEqual` if you don't need a deep comparison and just want to check\n * for simple (`===`, `Object.is`) equality.\n * - `isDeepEqual` for a recursively deep check of arrays and objects.\n *\n * @param data - The first value to compare.\n * @param other - The second value to compare.\n * @signature\n * isShallowEqual(data, other)\n * @example\n * isShallowEqual(1, 1) //=> true\n * isShallowEqual(1, '1') //=> false\n * isShallowEqual([1, 2, 3], [1, 2, 3]) //=> true\n * isShallowEqual([[1], [2], [3]], [[1], [2], [3]]) //=> false\n * @dataFirst\n * @category Guard\n */\nexport function isShallowEqual<T, S extends T>(\n data: T,\n other: T extends Exclude<T, S> ? S : never,\n): data is S;\nexport function isShallowEqual<T>(data: T, other: T): boolean;\n\n/**\n * Performs a *shallow structural* comparison between two values to determine if\n * they are equivalent. For primitive values this is equivalent to `===`, for\n * arrays a **strict equality** check would be performed on every item, in\n * order, and for objects props will be matched and checked for **strict\n * equality**; Unlike `isDeepEqual` where the function also *recurses* into each\n * item and value.\n *\n * !IMPORTANT: symbol properties of objects are not supported right now and\n * might result in unexpected behavior. Please open an issue in the Perkakas\n * github project if you need support for these types.\n *\n * !IMPORTANT: All built-in objects (Promise, Date, RegExp) are shallowly equal,\n * even when they are semantically different (e.g. resolved promises). Use\n * `isDeepEqual` instead.\n *\n * The result would be narrowed to the second value so that the function can be\n * used as a type guard.\n *\n * See:\n * - `isStrictEqual` if you don't need a deep comparison and just want to check\n * for simple (`===`, `Object.is`) equality.\n * - `isDeepEqual` for a recursively deep check of arrays and objects.\n *\n * @param other - The second value to compare.\n * @signature\n * isShallowEqual(other)(data)\n * @example\n * pipe(1, isShallowEqual(1)) //=> true\n * pipe(1, isShallowEqual('1')) //=> false\n * pipe([1, 2, 3], isShallowEqual([1, 2, 3])) //=> true\n * pipe([[1], [2], [3]], isShallowEqual([[1], [2], [3]])) //=> false\n * @dataFirst\n * @category Guard\n */\nexport function isShallowEqual<T, S extends T>(\n other: T extends Exclude<T, S> ? S : never,\n): (data: T) => data is S;\nexport function isShallowEqual<T>(other: T): (data: T) => boolean;\n\nexport function isShallowEqual(...args: ReadonlyArray<unknown>): unknown {\n return curry(isShallowEqualImplementation, args);\n}\n\nfunction isShallowEqualImplementation<T>(a: T, b: T): boolean {\n if (a === b || Object.is(a, b)) {\n return true;\n }\n\n if (\n typeof a !== 'object'\n || a === null\n || typeof b !== 'object'\n || b === null\n ) {\n return false;\n }\n\n if (a instanceof Map && b instanceof Map) {\n return isMapShallowEqual(a, b);\n }\n\n if (a instanceof Set && b instanceof Set) {\n return isSetShallowEqual(a, b);\n }\n\n const keys = Object.keys(a);\n if (keys.length !== Object.keys(b).length) {\n return false;\n }\n\n for (const key of keys) {\n if (!Object.hasOwn(b, key)) {\n return false;\n }\n\n const { [key as keyof T]: valueA } = a;\n const { [key as keyof T]: valueB } = b;\n\n if (valueA !== valueB || !Object.is(valueA, valueB)) {\n return false;\n }\n }\n\n return true;\n}\n\nfunction isMapShallowEqual(\n a: ReadonlyMap<unknown, unknown>,\n b: ReadonlyMap<unknown, unknown>,\n): boolean {\n if (a.size !== b.size) {\n return false;\n }\n\n for (const [key, value] of a) {\n const valueB = b.get(key);\n if (value !== valueB || !Object.is(value, valueB)) {\n return false;\n }\n }\n\n return true;\n}\n\nfunction isSetShallowEqual(\n a: ReadonlySet<unknown>,\n b: ReadonlySet<unknown>,\n): boolean {\n if (a.size !== b.size) {\n return false;\n }\n\n for (const value of a) {\n if (!b.has(value)) {\n return false;\n }\n }\n\n return true;\n}\n"],"mappings":"kGAoFA,SAAgB,EAAe,GAAG,EAAuC,CACvE,OAAOA,EAAAA,MAAM,EAA8B,EAAK,CAGlD,SAAS,EAAgC,EAAM,EAAe,CAC5D,GAAI,IAAM,GAAK,OAAO,GAAG,EAAG,EAAE,CAC5B,MAAO,GAGT,GACE,OAAO,GAAM,WACV,GACA,OAAO,GAAM,WACb,EAEH,MAAO,GAGT,GAAI,aAAa,KAAO,aAAa,IACnC,OAAO,EAAkB,EAAG,EAAE,CAGhC,GAAI,aAAa,KAAO,aAAa,IACnC,OAAO,EAAkB,EAAG,EAAE,CAGhC,IAAM,EAAO,OAAO,KAAK,EAAE,CAC3B,GAAI,EAAK,SAAW,OAAO,KAAK,EAAE,CAAC,OACjC,MAAO,GAGT,IAAK,IAAM,KAAO,EAAM,CACtB,GAAI,CAAC,OAAO,OAAO,EAAG,EAAI,CACxB,MAAO,GAGT,GAAM,EAAG,GAAiB,GAAW,EAC/B,EAAG,GAAiB,GAAW,EAErC,GAAI,IAAW,GAAU,CAAC,OAAO,GAAG,EAAQ,EAAO,CACjD,MAAO,GAIX,MAAO,GAGT,SAAS,EACP,EACA,EACS,CACT,GAAI,EAAE,OAAS,EAAE,KACf,MAAO,GAGT,IAAK,GAAM,CAAC,EAAK,KAAU,EAAG,CAC5B,IAAM,EAAS,EAAE,IAAI,EAAI,CACzB,GAAI,IAAU,GAAU,CAAC,OAAO,GAAG,EAAO,EAAO,CAC/C,MAAO,GAIX,MAAO,GAGT,SAAS,EACP,EACA,EACS,CACT,GAAI,EAAE,OAAS,EAAE,KACf,MAAO,GAGT,IAAK,IAAM,KAAS,EAClB,GAAI,CAAC,EAAE,IAAI,EAAM,CACf,MAAO,GAIX,MAAO"}
1
+ {"version":3,"file":"is-shallow-equal.cjs","names":["curry"],"sources":["../src/is-shallow-equal.ts"],"sourcesContent":["import { curry } from './curry';\n\n/**\n * Performs a *shallow structural* comparison between two values to determine if\n * they are equivalent. For primitive values this is equivalent to `===`, for\n * arrays a **strict equality** check would be performed on every item, in\n * order, and for objects props will be matched and checked for **strict\n * equality**; Unlike `isDeepEqual` where the function also *recurses* into each\n * item and value.\n *\n * !IMPORTANT: symbol properties of objects are not supported right now and\n * might result in unexpected behavior. Please open an issue in the Perkakas\n * github project if you need support for these types.\n *\n * !IMPORTANT: Promise, Date, and RegExp, are shallowly equal, even when they\n * are semantically different (e.g. resolved promises); but `isDeepEqual` does\n * compare the latter 2 semantically by-value.\n *\n * The result would be narrowed to the second value so that the function can be\n * used as a type guard.\n *\n * See:\n * - `isStrictEqual` if you don't need a deep comparison and just want to check\n * for simple (`===`, `Object.is`) equality.\n * - `isDeepEqual` for a recursively deep check of arrays and objects.\n *\n * @param data - The first value to compare.\n * @param other - The second value to compare.\n * @signature\n * isShallowEqual(data, other)\n * @example\n * isShallowEqual(1, 1) //=> true\n * isShallowEqual(1, '1') //=> false\n * isShallowEqual([1, 2, 3], [1, 2, 3]) //=> true\n * isShallowEqual([[1], [2], [3]], [[1], [2], [3]]) //=> false\n * @dataFirst\n * @category Guard\n */\nexport function isShallowEqual<T, S extends T>(\n data: T,\n other: T extends Exclude<T, S> ? S : never,\n): data is S;\nexport function isShallowEqual<T>(data: T, other: T): boolean;\n\n/**\n * Performs a *shallow structural* comparison between two values to determine if\n * they are equivalent. For primitive values this is equivalent to `===`, for\n * arrays a **strict equality** check would be performed on every item, in\n * order, and for objects props will be matched and checked for **strict\n * equality**; Unlike `isDeepEqual` where the function also *recurses* into each\n * item and value.\n *\n * !IMPORTANT: symbol properties of objects are not supported right now and\n * might result in unexpected behavior. Please open an issue in the Perkakas\n * github project if you need support for these types.\n *\n * !IMPORTANT: All built-in objects (Promise, Date, RegExp) are shallowly equal,\n * even when they are semantically different (e.g. resolved promises). Use\n * `isDeepEqual` instead.\n *\n * The result would be narrowed to the second value so that the function can be\n * used as a type guard.\n *\n * See:\n * - `isStrictEqual` if you don't need a deep comparison and just want to check\n * for simple (`===`, `Object.is`) equality.\n * - `isDeepEqual` for a recursively deep check of arrays and objects.\n *\n * @param other - The second value to compare.\n * @signature\n * isShallowEqual(other)(data)\n * @example\n * pipe(1, isShallowEqual(1)) //=> true\n * pipe(1, isShallowEqual('1')) //=> false\n * pipe([1, 2, 3], isShallowEqual([1, 2, 3])) //=> true\n * pipe([[1], [2], [3]], isShallowEqual([[1], [2], [3]])) //=> false\n * @dataFirst\n * @category Guard\n */\nexport function isShallowEqual<T, S extends T>(\n other: T extends Exclude<T, S> ? S : never,\n): (data: T) => data is S;\nexport function isShallowEqual<T>(other: T): (data: T) => boolean;\n\nexport function isShallowEqual(...args: ReadonlyArray<unknown>): unknown {\n return curry(isShallowEqualImplementation, args);\n}\n\nfunction isShallowEqualImplementation<T>(a: T, b: T): boolean {\n if (a === b || Object.is(a, b)) {\n return true;\n }\n\n if (\n typeof a !== 'object'\n || a === null\n || typeof b !== 'object'\n || b === null\n ) {\n return false;\n }\n\n if (a instanceof Map && b instanceof Map) {\n return isMapShallowEqual(a, b);\n }\n\n if (a instanceof Set && b instanceof Set) {\n return isSetShallowEqual(a, b);\n }\n\n const keys = Object.keys(a);\n if (keys.length !== Object.keys(b).length) {\n return false;\n }\n\n for (const key of keys) {\n if (!Object.hasOwn(b, key)) {\n return false;\n }\n\n const { [key as keyof T]: valueA } = a;\n const { [key as keyof T]: valueB } = b;\n\n if (valueA !== valueB || !Object.is(valueA, valueB)) {\n return false;\n }\n }\n\n return true;\n}\n\nfunction isMapShallowEqual(\n a: ReadonlyMap<unknown, unknown>,\n b: ReadonlyMap<unknown, unknown>,\n): boolean {\n if (a.size !== b.size) {\n return false;\n }\n\n for (const [key, value] of a) {\n const valueB = b.get(key);\n if (value !== valueB || !Object.is(value, valueB)) {\n return false;\n }\n }\n\n return true;\n}\n\nfunction isSetShallowEqual(\n a: ReadonlySet<unknown>,\n b: ReadonlySet<unknown>,\n): boolean {\n if (a.size !== b.size) {\n return false;\n }\n\n for (const value of a) {\n if (!b.has(value)) {\n return false;\n }\n }\n\n return true;\n}\n"],"mappings":"kGAoFA,SAAgB,EAAe,GAAG,EAAuC,CACvE,OAAOA,EAAAA,MAAM,EAA8B,CAAI,CACjD,CAEA,SAAS,EAAgC,EAAM,EAAe,CAC5D,GAAI,IAAM,GAAK,OAAO,GAAG,EAAG,CAAC,EAC3B,MAAO,GAGT,GACE,OAAO,GAAM,WACV,GACA,OAAO,GAAM,WACb,EAEH,MAAO,GAGT,GAAI,aAAa,KAAO,aAAa,IACnC,OAAO,EAAkB,EAAG,CAAC,EAG/B,GAAI,aAAa,KAAO,aAAa,IACnC,OAAO,EAAkB,EAAG,CAAC,EAG/B,IAAM,EAAO,OAAO,KAAK,CAAC,EAC1B,GAAI,EAAK,SAAW,OAAO,KAAK,CAAC,CAAC,CAAC,OACjC,MAAO,GAGT,IAAK,IAAM,KAAO,EAAM,CACtB,GAAI,CAAC,OAAO,OAAO,EAAG,CAAG,EACvB,MAAO,GAGT,GAAM,EAAG,GAAiB,GAAW,EAC/B,EAAG,GAAiB,GAAW,EAErC,GAAI,IAAW,GAAU,CAAC,OAAO,GAAG,EAAQ,CAAM,EAChD,MAAO,EAEX,CAEA,MAAO,EACT,CAEA,SAAS,EACP,EACA,EACS,CACT,GAAI,EAAE,OAAS,EAAE,KACf,MAAO,GAGT,IAAK,GAAM,CAAC,EAAK,KAAU,EAAG,CAC5B,IAAM,EAAS,EAAE,IAAI,CAAG,EACxB,GAAI,IAAU,GAAU,CAAC,OAAO,GAAG,EAAO,CAAM,EAC9C,MAAO,EAEX,CAEA,MAAO,EACT,CAEA,SAAS,EACP,EACA,EACS,CACT,GAAI,EAAE,OAAS,EAAE,KACf,MAAO,GAGT,IAAK,IAAM,KAAS,EAClB,GAAI,CAAC,EAAE,IAAI,CAAK,EACd,MAAO,GAIX,MAAO,EACT"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-shallow-equal.js","names":[],"sources":["../src/is-shallow-equal.ts"],"sourcesContent":["import { curry } from './curry';\n\n/**\n * Performs a *shallow structural* comparison between two values to determine if\n * they are equivalent. For primitive values this is equivalent to `===`, for\n * arrays a **strict equality** check would be performed on every item, in\n * order, and for objects props will be matched and checked for **strict\n * equality**; Unlike `isDeepEqual` where the function also *recurses* into each\n * item and value.\n *\n * !IMPORTANT: symbol properties of objects are not supported right now and\n * might result in unexpected behavior. Please open an issue in the Perkakas\n * github project if you need support for these types.\n *\n * !IMPORTANT: Promise, Date, and RegExp, are shallowly equal, even when they\n * are semantically different (e.g. resolved promises); but `isDeepEqual` does\n * compare the latter 2 semantically by-value.\n *\n * The result would be narrowed to the second value so that the function can be\n * used as a type guard.\n *\n * See:\n * - `isStrictEqual` if you don't need a deep comparison and just want to check\n * for simple (`===`, `Object.is`) equality.\n * - `isDeepEqual` for a recursively deep check of arrays and objects.\n *\n * @param data - The first value to compare.\n * @param other - The second value to compare.\n * @signature\n * isShallowEqual(data, other)\n * @example\n * isShallowEqual(1, 1) //=> true\n * isShallowEqual(1, '1') //=> false\n * isShallowEqual([1, 2, 3], [1, 2, 3]) //=> true\n * isShallowEqual([[1], [2], [3]], [[1], [2], [3]]) //=> false\n * @dataFirst\n * @category Guard\n */\nexport function isShallowEqual<T, S extends T>(\n data: T,\n other: T extends Exclude<T, S> ? S : never,\n): data is S;\nexport function isShallowEqual<T>(data: T, other: T): boolean;\n\n/**\n * Performs a *shallow structural* comparison between two values to determine if\n * they are equivalent. For primitive values this is equivalent to `===`, for\n * arrays a **strict equality** check would be performed on every item, in\n * order, and for objects props will be matched and checked for **strict\n * equality**; Unlike `isDeepEqual` where the function also *recurses* into each\n * item and value.\n *\n * !IMPORTANT: symbol properties of objects are not supported right now and\n * might result in unexpected behavior. Please open an issue in the Perkakas\n * github project if you need support for these types.\n *\n * !IMPORTANT: All built-in objects (Promise, Date, RegExp) are shallowly equal,\n * even when they are semantically different (e.g. resolved promises). Use\n * `isDeepEqual` instead.\n *\n * The result would be narrowed to the second value so that the function can be\n * used as a type guard.\n *\n * See:\n * - `isStrictEqual` if you don't need a deep comparison and just want to check\n * for simple (`===`, `Object.is`) equality.\n * - `isDeepEqual` for a recursively deep check of arrays and objects.\n *\n * @param other - The second value to compare.\n * @signature\n * isShallowEqual(other)(data)\n * @example\n * pipe(1, isShallowEqual(1)) //=> true\n * pipe(1, isShallowEqual('1')) //=> false\n * pipe([1, 2, 3], isShallowEqual([1, 2, 3])) //=> true\n * pipe([[1], [2], [3]], isShallowEqual([[1], [2], [3]])) //=> false\n * @dataFirst\n * @category Guard\n */\nexport function isShallowEqual<T, S extends T>(\n other: T extends Exclude<T, S> ? S : never,\n): (data: T) => data is S;\nexport function isShallowEqual<T>(other: T): (data: T) => boolean;\n\nexport function isShallowEqual(...args: ReadonlyArray<unknown>): unknown {\n return curry(isShallowEqualImplementation, args);\n}\n\nfunction isShallowEqualImplementation<T>(a: T, b: T): boolean {\n if (a === b || Object.is(a, b)) {\n return true;\n }\n\n if (\n typeof a !== 'object'\n || a === null\n || typeof b !== 'object'\n || b === null\n ) {\n return false;\n }\n\n if (a instanceof Map && b instanceof Map) {\n return isMapShallowEqual(a, b);\n }\n\n if (a instanceof Set && b instanceof Set) {\n return isSetShallowEqual(a, b);\n }\n\n const keys = Object.keys(a);\n if (keys.length !== Object.keys(b).length) {\n return false;\n }\n\n for (const key of keys) {\n if (!Object.hasOwn(b, key)) {\n return false;\n }\n\n const { [key as keyof T]: valueA } = a;\n const { [key as keyof T]: valueB } = b;\n\n if (valueA !== valueB || !Object.is(valueA, valueB)) {\n return false;\n }\n }\n\n return true;\n}\n\nfunction isMapShallowEqual(\n a: ReadonlyMap<unknown, unknown>,\n b: ReadonlyMap<unknown, unknown>,\n): boolean {\n if (a.size !== b.size) {\n return false;\n }\n\n for (const [key, value] of a) {\n const valueB = b.get(key);\n if (value !== valueB || !Object.is(value, valueB)) {\n return false;\n }\n }\n\n return true;\n}\n\nfunction isSetShallowEqual(\n a: ReadonlySet<unknown>,\n b: ReadonlySet<unknown>,\n): boolean {\n if (a.size !== b.size) {\n return false;\n }\n\n for (const value of a) {\n if (!b.has(value)) {\n return false;\n }\n }\n\n return true;\n}\n"],"mappings":"mCAoFA,SAAgB,EAAe,GAAG,EAAuC,CACvE,OAAO,EAAM,EAA8B,EAAK,CAGlD,SAAS,EAAgC,EAAM,EAAe,CAC5D,GAAI,IAAM,GAAK,OAAO,GAAG,EAAG,EAAE,CAC5B,MAAO,GAGT,GACE,OAAO,GAAM,WACV,GACA,OAAO,GAAM,WACb,EAEH,MAAO,GAGT,GAAI,aAAa,KAAO,aAAa,IACnC,OAAO,EAAkB,EAAG,EAAE,CAGhC,GAAI,aAAa,KAAO,aAAa,IACnC,OAAO,EAAkB,EAAG,EAAE,CAGhC,IAAM,EAAO,OAAO,KAAK,EAAE,CAC3B,GAAI,EAAK,SAAW,OAAO,KAAK,EAAE,CAAC,OACjC,MAAO,GAGT,IAAK,IAAM,KAAO,EAAM,CACtB,GAAI,CAAC,OAAO,OAAO,EAAG,EAAI,CACxB,MAAO,GAGT,GAAM,EAAG,GAAiB,GAAW,EAC/B,EAAG,GAAiB,GAAW,EAErC,GAAI,IAAW,GAAU,CAAC,OAAO,GAAG,EAAQ,EAAO,CACjD,MAAO,GAIX,MAAO,GAGT,SAAS,EACP,EACA,EACS,CACT,GAAI,EAAE,OAAS,EAAE,KACf,MAAO,GAGT,IAAK,GAAM,CAAC,EAAK,KAAU,EAAG,CAC5B,IAAM,EAAS,EAAE,IAAI,EAAI,CACzB,GAAI,IAAU,GAAU,CAAC,OAAO,GAAG,EAAO,EAAO,CAC/C,MAAO,GAIX,MAAO,GAGT,SAAS,EACP,EACA,EACS,CACT,GAAI,EAAE,OAAS,EAAE,KACf,MAAO,GAGT,IAAK,IAAM,KAAS,EAClB,GAAI,CAAC,EAAE,IAAI,EAAM,CACf,MAAO,GAIX,MAAO"}
1
+ {"version":3,"file":"is-shallow-equal.js","names":[],"sources":["../src/is-shallow-equal.ts"],"sourcesContent":["import { curry } from './curry';\n\n/**\n * Performs a *shallow structural* comparison between two values to determine if\n * they are equivalent. For primitive values this is equivalent to `===`, for\n * arrays a **strict equality** check would be performed on every item, in\n * order, and for objects props will be matched and checked for **strict\n * equality**; Unlike `isDeepEqual` where the function also *recurses* into each\n * item and value.\n *\n * !IMPORTANT: symbol properties of objects are not supported right now and\n * might result in unexpected behavior. Please open an issue in the Perkakas\n * github project if you need support for these types.\n *\n * !IMPORTANT: Promise, Date, and RegExp, are shallowly equal, even when they\n * are semantically different (e.g. resolved promises); but `isDeepEqual` does\n * compare the latter 2 semantically by-value.\n *\n * The result would be narrowed to the second value so that the function can be\n * used as a type guard.\n *\n * See:\n * - `isStrictEqual` if you don't need a deep comparison and just want to check\n * for simple (`===`, `Object.is`) equality.\n * - `isDeepEqual` for a recursively deep check of arrays and objects.\n *\n * @param data - The first value to compare.\n * @param other - The second value to compare.\n * @signature\n * isShallowEqual(data, other)\n * @example\n * isShallowEqual(1, 1) //=> true\n * isShallowEqual(1, '1') //=> false\n * isShallowEqual([1, 2, 3], [1, 2, 3]) //=> true\n * isShallowEqual([[1], [2], [3]], [[1], [2], [3]]) //=> false\n * @dataFirst\n * @category Guard\n */\nexport function isShallowEqual<T, S extends T>(\n data: T,\n other: T extends Exclude<T, S> ? S : never,\n): data is S;\nexport function isShallowEqual<T>(data: T, other: T): boolean;\n\n/**\n * Performs a *shallow structural* comparison between two values to determine if\n * they are equivalent. For primitive values this is equivalent to `===`, for\n * arrays a **strict equality** check would be performed on every item, in\n * order, and for objects props will be matched and checked for **strict\n * equality**; Unlike `isDeepEqual` where the function also *recurses* into each\n * item and value.\n *\n * !IMPORTANT: symbol properties of objects are not supported right now and\n * might result in unexpected behavior. Please open an issue in the Perkakas\n * github project if you need support for these types.\n *\n * !IMPORTANT: All built-in objects (Promise, Date, RegExp) are shallowly equal,\n * even when they are semantically different (e.g. resolved promises). Use\n * `isDeepEqual` instead.\n *\n * The result would be narrowed to the second value so that the function can be\n * used as a type guard.\n *\n * See:\n * - `isStrictEqual` if you don't need a deep comparison and just want to check\n * for simple (`===`, `Object.is`) equality.\n * - `isDeepEqual` for a recursively deep check of arrays and objects.\n *\n * @param other - The second value to compare.\n * @signature\n * isShallowEqual(other)(data)\n * @example\n * pipe(1, isShallowEqual(1)) //=> true\n * pipe(1, isShallowEqual('1')) //=> false\n * pipe([1, 2, 3], isShallowEqual([1, 2, 3])) //=> true\n * pipe([[1], [2], [3]], isShallowEqual([[1], [2], [3]])) //=> false\n * @dataFirst\n * @category Guard\n */\nexport function isShallowEqual<T, S extends T>(\n other: T extends Exclude<T, S> ? S : never,\n): (data: T) => data is S;\nexport function isShallowEqual<T>(other: T): (data: T) => boolean;\n\nexport function isShallowEqual(...args: ReadonlyArray<unknown>): unknown {\n return curry(isShallowEqualImplementation, args);\n}\n\nfunction isShallowEqualImplementation<T>(a: T, b: T): boolean {\n if (a === b || Object.is(a, b)) {\n return true;\n }\n\n if (\n typeof a !== 'object'\n || a === null\n || typeof b !== 'object'\n || b === null\n ) {\n return false;\n }\n\n if (a instanceof Map && b instanceof Map) {\n return isMapShallowEqual(a, b);\n }\n\n if (a instanceof Set && b instanceof Set) {\n return isSetShallowEqual(a, b);\n }\n\n const keys = Object.keys(a);\n if (keys.length !== Object.keys(b).length) {\n return false;\n }\n\n for (const key of keys) {\n if (!Object.hasOwn(b, key)) {\n return false;\n }\n\n const { [key as keyof T]: valueA } = a;\n const { [key as keyof T]: valueB } = b;\n\n if (valueA !== valueB || !Object.is(valueA, valueB)) {\n return false;\n }\n }\n\n return true;\n}\n\nfunction isMapShallowEqual(\n a: ReadonlyMap<unknown, unknown>,\n b: ReadonlyMap<unknown, unknown>,\n): boolean {\n if (a.size !== b.size) {\n return false;\n }\n\n for (const [key, value] of a) {\n const valueB = b.get(key);\n if (value !== valueB || !Object.is(value, valueB)) {\n return false;\n }\n }\n\n return true;\n}\n\nfunction isSetShallowEqual(\n a: ReadonlySet<unknown>,\n b: ReadonlySet<unknown>,\n): boolean {\n if (a.size !== b.size) {\n return false;\n }\n\n for (const value of a) {\n if (!b.has(value)) {\n return false;\n }\n }\n\n return true;\n}\n"],"mappings":"mCAoFA,SAAgB,EAAe,GAAG,EAAuC,CACvE,OAAO,EAAM,EAA8B,CAAI,CACjD,CAEA,SAAS,EAAgC,EAAM,EAAe,CAC5D,GAAI,IAAM,GAAK,OAAO,GAAG,EAAG,CAAC,EAC3B,MAAO,GAGT,GACE,OAAO,GAAM,WACV,GACA,OAAO,GAAM,WACb,EAEH,MAAO,GAGT,GAAI,aAAa,KAAO,aAAa,IACnC,OAAO,EAAkB,EAAG,CAAC,EAG/B,GAAI,aAAa,KAAO,aAAa,IACnC,OAAO,EAAkB,EAAG,CAAC,EAG/B,IAAM,EAAO,OAAO,KAAK,CAAC,EAC1B,GAAI,EAAK,SAAW,OAAO,KAAK,CAAC,CAAC,CAAC,OACjC,MAAO,GAGT,IAAK,IAAM,KAAO,EAAM,CACtB,GAAI,CAAC,OAAO,OAAO,EAAG,CAAG,EACvB,MAAO,GAGT,GAAM,EAAG,GAAiB,GAAW,EAC/B,EAAG,GAAiB,GAAW,EAErC,GAAI,IAAW,GAAU,CAAC,OAAO,GAAG,EAAQ,CAAM,EAChD,MAAO,EAEX,CAEA,MAAO,EACT,CAEA,SAAS,EACP,EACA,EACS,CACT,GAAI,EAAE,OAAS,EAAE,KACf,MAAO,GAGT,IAAK,GAAM,CAAC,EAAK,KAAU,EAAG,CAC5B,IAAM,EAAS,EAAE,IAAI,CAAG,EACxB,GAAI,IAAU,GAAU,CAAC,OAAO,GAAG,EAAO,CAAM,EAC9C,MAAO,EAEX,CAEA,MAAO,EACT,CAEA,SAAS,EACP,EACA,EACS,CACT,GAAI,EAAE,OAAS,EAAE,KACf,MAAO,GAGT,IAAK,IAAM,KAAS,EAClB,GAAI,CAAC,EAAE,IAAI,CAAK,EACd,MAAO,GAIX,MAAO,EACT"}
@@ -1,2 +1,2 @@
1
- Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require(`./curry.cjs`);function t(...t){return e.curry(n,t)}function n(e,t){return e===t||Object.is(e,t)}exports.isStrictEqual=t;
1
+ Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./curry.cjs");function t(...t){return e.curry(n,t)}function n(e,t){return e===t||Object.is(e,t)}exports.isStrictEqual=t;
2
2
  //# sourceMappingURL=is-strict-equal.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"is-strict-equal.cjs","names":["curry"],"sources":["../src/is-strict-equal.ts"],"sourcesContent":["import { curry } from './curry';\n\n/**\n * Determines whether two values are *functionally identical* in all contexts.\n * For primitive values (string, number), this is done by-value, and for objects\n * it is done by-reference (i.e., they point to the same object in memory).\n *\n * Under the hood we use **both** the [`===` operator](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Strict_equality)\n * and [`Object.is`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is). This means that `isStrictEqual(NaN, NaN) === true`\n * (whereas `NaN !== NaN`), and `isStrictEqual(-0, 0) === true` (whereas\n * `Object.is(-0, 0) === false`).\n *\n * The result would be narrowed to the second value so that the function can be\n * used as a type guard.\n *\n * See:\n * - `isDeepEqual` for a semantic comparison that allows comparing arrays and\n * objects \"by-value\", and recurses for every item.\n * - `isShallowEqual` if you need to compare arrays and objects \"by-value\" but\n * don't want to recurse into their values.\n *\n * @param data - The first value to compare.\n * @param other - The second value to compare.\n * @signature\n * isStrictEqual(data, other)\n * @example\n * isStrictEqual(1, 1) //=> true\n * isStrictEqual(1, '1') //=> false\n * isStrictEqual([1, 2, 3], [1, 2, 3]) //=> false\n * @dataFirst\n * @category Guard\n */\nexport function isStrictEqual<T, S extends T>(\n data: T,\n other: T extends Exclude<T, S> ? S : never,\n): data is S;\nexport function isStrictEqual<T>(data: T, other: T): boolean;\n\n/**\n * Determines whether two values are *functionally identical* in all contexts.\n * For primitive values (string, number), this is done by-value, and for objects\n * it is done by-reference (i.e., they point to the same object in memory).\n *\n * Under the hood we use **both** the [`===` operator](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Strict_equality)\n * and [`Object.is`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is). This means that `isStrictEqual(NaN, NaN) === true`\n * (whereas `NaN !== NaN`), and `isStrictEqual(-0, 0) === true` (whereas\n * `Object.is(-0, 0) === false`).\n *\n * The result would be narrowed to the second value so that the function can be\n * used as a type guard.\n *\n * See:\n * - `isDeepEqual` for a semantic comparison that allows comparing arrays and\n * objects \"by-value\", and recurses for every item.\n * - `isShallowEqual` if you need to compare arrays and objects \"by-value\" but\n * don't want to recurse into their values.\n *\n * @param other - The second value to compare.\n * @signature\n * isStrictEqual(other)(data)\n * @example\n * pipe(1, isStrictEqual(1)); //=> true\n * pipe(1, isStrictEqual('1')); //=> false\n * pipe([1, 2, 3], isStrictEqual([1, 2, 3])); //=> false\n * @dataLast\n * @category Guard\n */\nexport function isStrictEqual<T, S extends T>(\n other: T extends Exclude<T, S> ? S : never,\n): (data: T) => data is S;\nexport function isStrictEqual<T>(other: T): (data: T) => boolean;\n\nexport function isStrictEqual(...args: ReadonlyArray<unknown>): unknown {\n return curry(isStrictlyEqualImplementation, args);\n}\n\nfunction isStrictlyEqualImplementation<T>(data: unknown, other: T): data is T {\n return data === other || Object.is(data, other);\n}\n"],"mappings":"kGAwEA,SAAgB,EAAc,GAAG,EAAuC,CACtE,OAAOA,EAAAA,MAAM,EAA+B,EAAK,CAGnD,SAAS,EAAiC,EAAe,EAAqB,CAC5E,OAAO,IAAS,GAAS,OAAO,GAAG,EAAM,EAAM"}
1
+ {"version":3,"file":"is-strict-equal.cjs","names":["curry"],"sources":["../src/is-strict-equal.ts"],"sourcesContent":["import { curry } from './curry';\n\n/**\n * Determines whether two values are *functionally identical* in all contexts.\n * For primitive values (string, number), this is done by-value, and for objects\n * it is done by-reference (i.e., they point to the same object in memory).\n *\n * Under the hood we use **both** the [`===` operator](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Strict_equality)\n * and [`Object.is`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is). This means that `isStrictEqual(NaN, NaN) === true`\n * (whereas `NaN !== NaN`), and `isStrictEqual(-0, 0) === true` (whereas\n * `Object.is(-0, 0) === false`).\n *\n * The result would be narrowed to the second value so that the function can be\n * used as a type guard.\n *\n * See:\n * - `isDeepEqual` for a semantic comparison that allows comparing arrays and\n * objects \"by-value\", and recurses for every item.\n * - `isShallowEqual` if you need to compare arrays and objects \"by-value\" but\n * don't want to recurse into their values.\n *\n * @param data - The first value to compare.\n * @param other - The second value to compare.\n * @signature\n * isStrictEqual(data, other)\n * @example\n * isStrictEqual(1, 1) //=> true\n * isStrictEqual(1, '1') //=> false\n * isStrictEqual([1, 2, 3], [1, 2, 3]) //=> false\n * @dataFirst\n * @category Guard\n */\nexport function isStrictEqual<T, S extends T>(\n data: T,\n other: T extends Exclude<T, S> ? S : never,\n): data is S;\nexport function isStrictEqual<T>(data: T, other: T): boolean;\n\n/**\n * Determines whether two values are *functionally identical* in all contexts.\n * For primitive values (string, number), this is done by-value, and for objects\n * it is done by-reference (i.e., they point to the same object in memory).\n *\n * Under the hood we use **both** the [`===` operator](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Strict_equality)\n * and [`Object.is`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is). This means that `isStrictEqual(NaN, NaN) === true`\n * (whereas `NaN !== NaN`), and `isStrictEqual(-0, 0) === true` (whereas\n * `Object.is(-0, 0) === false`).\n *\n * The result would be narrowed to the second value so that the function can be\n * used as a type guard.\n *\n * See:\n * - `isDeepEqual` for a semantic comparison that allows comparing arrays and\n * objects \"by-value\", and recurses for every item.\n * - `isShallowEqual` if you need to compare arrays and objects \"by-value\" but\n * don't want to recurse into their values.\n *\n * @param other - The second value to compare.\n * @signature\n * isStrictEqual(other)(data)\n * @example\n * pipe(1, isStrictEqual(1)); //=> true\n * pipe(1, isStrictEqual('1')); //=> false\n * pipe([1, 2, 3], isStrictEqual([1, 2, 3])); //=> false\n * @dataLast\n * @category Guard\n */\nexport function isStrictEqual<T, S extends T>(\n other: T extends Exclude<T, S> ? S : never,\n): (data: T) => data is S;\nexport function isStrictEqual<T>(other: T): (data: T) => boolean;\n\nexport function isStrictEqual(...args: ReadonlyArray<unknown>): unknown {\n return curry(isStrictlyEqualImplementation, args);\n}\n\nfunction isStrictlyEqualImplementation<T>(data: unknown, other: T): data is T {\n return data === other || Object.is(data, other);\n}\n"],"mappings":"kGAwEA,SAAgB,EAAc,GAAG,EAAuC,CACtE,OAAOA,EAAAA,MAAM,EAA+B,CAAI,CAClD,CAEA,SAAS,EAAiC,EAAe,EAAqB,CAC5E,OAAO,IAAS,GAAS,OAAO,GAAG,EAAM,CAAK,CAChD"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-strict-equal.js","names":[],"sources":["../src/is-strict-equal.ts"],"sourcesContent":["import { curry } from './curry';\n\n/**\n * Determines whether two values are *functionally identical* in all contexts.\n * For primitive values (string, number), this is done by-value, and for objects\n * it is done by-reference (i.e., they point to the same object in memory).\n *\n * Under the hood we use **both** the [`===` operator](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Strict_equality)\n * and [`Object.is`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is). This means that `isStrictEqual(NaN, NaN) === true`\n * (whereas `NaN !== NaN`), and `isStrictEqual(-0, 0) === true` (whereas\n * `Object.is(-0, 0) === false`).\n *\n * The result would be narrowed to the second value so that the function can be\n * used as a type guard.\n *\n * See:\n * - `isDeepEqual` for a semantic comparison that allows comparing arrays and\n * objects \"by-value\", and recurses for every item.\n * - `isShallowEqual` if you need to compare arrays and objects \"by-value\" but\n * don't want to recurse into their values.\n *\n * @param data - The first value to compare.\n * @param other - The second value to compare.\n * @signature\n * isStrictEqual(data, other)\n * @example\n * isStrictEqual(1, 1) //=> true\n * isStrictEqual(1, '1') //=> false\n * isStrictEqual([1, 2, 3], [1, 2, 3]) //=> false\n * @dataFirst\n * @category Guard\n */\nexport function isStrictEqual<T, S extends T>(\n data: T,\n other: T extends Exclude<T, S> ? S : never,\n): data is S;\nexport function isStrictEqual<T>(data: T, other: T): boolean;\n\n/**\n * Determines whether two values are *functionally identical* in all contexts.\n * For primitive values (string, number), this is done by-value, and for objects\n * it is done by-reference (i.e., they point to the same object in memory).\n *\n * Under the hood we use **both** the [`===` operator](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Strict_equality)\n * and [`Object.is`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is). This means that `isStrictEqual(NaN, NaN) === true`\n * (whereas `NaN !== NaN`), and `isStrictEqual(-0, 0) === true` (whereas\n * `Object.is(-0, 0) === false`).\n *\n * The result would be narrowed to the second value so that the function can be\n * used as a type guard.\n *\n * See:\n * - `isDeepEqual` for a semantic comparison that allows comparing arrays and\n * objects \"by-value\", and recurses for every item.\n * - `isShallowEqual` if you need to compare arrays and objects \"by-value\" but\n * don't want to recurse into their values.\n *\n * @param other - The second value to compare.\n * @signature\n * isStrictEqual(other)(data)\n * @example\n * pipe(1, isStrictEqual(1)); //=> true\n * pipe(1, isStrictEqual('1')); //=> false\n * pipe([1, 2, 3], isStrictEqual([1, 2, 3])); //=> false\n * @dataLast\n * @category Guard\n */\nexport function isStrictEqual<T, S extends T>(\n other: T extends Exclude<T, S> ? S : never,\n): (data: T) => data is S;\nexport function isStrictEqual<T>(other: T): (data: T) => boolean;\n\nexport function isStrictEqual(...args: ReadonlyArray<unknown>): unknown {\n return curry(isStrictlyEqualImplementation, args);\n}\n\nfunction isStrictlyEqualImplementation<T>(data: unknown, other: T): data is T {\n return data === other || Object.is(data, other);\n}\n"],"mappings":"mCAwEA,SAAgB,EAAc,GAAG,EAAuC,CACtE,OAAO,EAAM,EAA+B,EAAK,CAGnD,SAAS,EAAiC,EAAe,EAAqB,CAC5E,OAAO,IAAS,GAAS,OAAO,GAAG,EAAM,EAAM"}
1
+ {"version":3,"file":"is-strict-equal.js","names":[],"sources":["../src/is-strict-equal.ts"],"sourcesContent":["import { curry } from './curry';\n\n/**\n * Determines whether two values are *functionally identical* in all contexts.\n * For primitive values (string, number), this is done by-value, and for objects\n * it is done by-reference (i.e., they point to the same object in memory).\n *\n * Under the hood we use **both** the [`===` operator](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Strict_equality)\n * and [`Object.is`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is). This means that `isStrictEqual(NaN, NaN) === true`\n * (whereas `NaN !== NaN`), and `isStrictEqual(-0, 0) === true` (whereas\n * `Object.is(-0, 0) === false`).\n *\n * The result would be narrowed to the second value so that the function can be\n * used as a type guard.\n *\n * See:\n * - `isDeepEqual` for a semantic comparison that allows comparing arrays and\n * objects \"by-value\", and recurses for every item.\n * - `isShallowEqual` if you need to compare arrays and objects \"by-value\" but\n * don't want to recurse into their values.\n *\n * @param data - The first value to compare.\n * @param other - The second value to compare.\n * @signature\n * isStrictEqual(data, other)\n * @example\n * isStrictEqual(1, 1) //=> true\n * isStrictEqual(1, '1') //=> false\n * isStrictEqual([1, 2, 3], [1, 2, 3]) //=> false\n * @dataFirst\n * @category Guard\n */\nexport function isStrictEqual<T, S extends T>(\n data: T,\n other: T extends Exclude<T, S> ? S : never,\n): data is S;\nexport function isStrictEqual<T>(data: T, other: T): boolean;\n\n/**\n * Determines whether two values are *functionally identical* in all contexts.\n * For primitive values (string, number), this is done by-value, and for objects\n * it is done by-reference (i.e., they point to the same object in memory).\n *\n * Under the hood we use **both** the [`===` operator](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Strict_equality)\n * and [`Object.is`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is). This means that `isStrictEqual(NaN, NaN) === true`\n * (whereas `NaN !== NaN`), and `isStrictEqual(-0, 0) === true` (whereas\n * `Object.is(-0, 0) === false`).\n *\n * The result would be narrowed to the second value so that the function can be\n * used as a type guard.\n *\n * See:\n * - `isDeepEqual` for a semantic comparison that allows comparing arrays and\n * objects \"by-value\", and recurses for every item.\n * - `isShallowEqual` if you need to compare arrays and objects \"by-value\" but\n * don't want to recurse into their values.\n *\n * @param other - The second value to compare.\n * @signature\n * isStrictEqual(other)(data)\n * @example\n * pipe(1, isStrictEqual(1)); //=> true\n * pipe(1, isStrictEqual('1')); //=> false\n * pipe([1, 2, 3], isStrictEqual([1, 2, 3])); //=> false\n * @dataLast\n * @category Guard\n */\nexport function isStrictEqual<T, S extends T>(\n other: T extends Exclude<T, S> ? S : never,\n): (data: T) => data is S;\nexport function isStrictEqual<T>(other: T): (data: T) => boolean;\n\nexport function isStrictEqual(...args: ReadonlyArray<unknown>): unknown {\n return curry(isStrictlyEqualImplementation, args);\n}\n\nfunction isStrictlyEqualImplementation<T>(data: unknown, other: T): data is T {\n return data === other || Object.is(data, other);\n}\n"],"mappings":"mCAwEA,SAAgB,EAAc,GAAG,EAAuC,CACtE,OAAO,EAAM,EAA+B,CAAI,CAClD,CAEA,SAAS,EAAiC,EAAe,EAAqB,CAC5E,OAAO,IAAS,GAAS,OAAO,GAAG,EAAM,CAAK,CAChD"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-string.cjs","names":[],"sources":["../src/is-string.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * A function that checks if the passed parameter is a string and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is a string, false otherwise.\n * @signature\n * isString(data)\n * @example\n * isString('string') //=> true\n * isString(1) //=> false\n * @category Guard\n */\nexport function isString<T>(data: T | string): data is NarrowedTo<T, string> {\n return typeof data === 'string';\n}\n"],"mappings":"mEAcA,SAAgB,EAAY,EAAiD,CAC3E,OAAO,OAAO,GAAS"}
1
+ {"version":3,"file":"is-string.cjs","names":[],"sources":["../src/is-string.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * A function that checks if the passed parameter is a string and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is a string, false otherwise.\n * @signature\n * isString(data)\n * @example\n * isString('string') //=> true\n * isString(1) //=> false\n * @category Guard\n */\nexport function isString<T>(data: T | string): data is NarrowedTo<T, string> {\n return typeof data === 'string';\n}\n"],"mappings":"mEAcA,SAAgB,EAAY,EAAiD,CAC3E,OAAO,OAAO,GAAS,QACzB"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-string.js","names":[],"sources":["../src/is-string.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * A function that checks if the passed parameter is a string and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is a string, false otherwise.\n * @signature\n * isString(data)\n * @example\n * isString('string') //=> true\n * isString(1) //=> false\n * @category Guard\n */\nexport function isString<T>(data: T | string): data is NarrowedTo<T, string> {\n return typeof data === 'string';\n}\n"],"mappings":"AAcA,SAAgB,EAAY,EAAiD,CAC3E,OAAO,OAAO,GAAS"}
1
+ {"version":3,"file":"is-string.js","names":[],"sources":["../src/is-string.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * A function that checks if the passed parameter is a string and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is a string, false otherwise.\n * @signature\n * isString(data)\n * @example\n * isString('string') //=> true\n * isString(1) //=> false\n * @category Guard\n */\nexport function isString<T>(data: T | string): data is NarrowedTo<T, string> {\n return typeof data === 'string';\n}\n"],"mappings":"AAcA,SAAgB,EAAY,EAAiD,CAC3E,OAAO,OAAO,GAAS,QACzB"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-symbol.cjs","names":[],"sources":["../src/is-symbol.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * A function that checks if the passed parameter is a symbol and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is a symbol, false otherwise.\n * @signature\n * isSymbol(data)\n * @example\n * isSymbol(Symbol('foo')) //=> true\n * isSymbol(1) //=> false\n * @category Guard\n */\nexport function isSymbol<T>(data: T | symbol): data is NarrowedTo<T, symbol> {\n return typeof data === 'symbol';\n}\n"],"mappings":"mEAcA,SAAgB,EAAY,EAAiD,CAC3E,OAAO,OAAO,GAAS"}
1
+ {"version":3,"file":"is-symbol.cjs","names":[],"sources":["../src/is-symbol.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * A function that checks if the passed parameter is a symbol and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is a symbol, false otherwise.\n * @signature\n * isSymbol(data)\n * @example\n * isSymbol(Symbol('foo')) //=> true\n * isSymbol(1) //=> false\n * @category Guard\n */\nexport function isSymbol<T>(data: T | symbol): data is NarrowedTo<T, symbol> {\n return typeof data === 'symbol';\n}\n"],"mappings":"mEAcA,SAAgB,EAAY,EAAiD,CAC3E,OAAO,OAAO,GAAS,QACzB"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-symbol.js","names":[],"sources":["../src/is-symbol.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * A function that checks if the passed parameter is a symbol and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is a symbol, false otherwise.\n * @signature\n * isSymbol(data)\n * @example\n * isSymbol(Symbol('foo')) //=> true\n * isSymbol(1) //=> false\n * @category Guard\n */\nexport function isSymbol<T>(data: T | symbol): data is NarrowedTo<T, symbol> {\n return typeof data === 'symbol';\n}\n"],"mappings":"AAcA,SAAgB,EAAY,EAAiD,CAC3E,OAAO,OAAO,GAAS"}
1
+ {"version":3,"file":"is-symbol.js","names":[],"sources":["../src/is-symbol.ts"],"sourcesContent":["import type { NarrowedTo } from './internal/types/narrowed-to';\n\n/**\n * A function that checks if the passed parameter is a symbol and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is a symbol, false otherwise.\n * @signature\n * isSymbol(data)\n * @example\n * isSymbol(Symbol('foo')) //=> true\n * isSymbol(1) //=> false\n * @category Guard\n */\nexport function isSymbol<T>(data: T | symbol): data is NarrowedTo<T, symbol> {\n return typeof data === 'symbol';\n}\n"],"mappings":"AAcA,SAAgB,EAAY,EAAiD,CAC3E,OAAO,OAAO,GAAS,QACzB"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-truthy.cjs","names":[],"sources":["../src/is-truthy.ts"],"sourcesContent":["/**\n * A function that checks if the passed parameter is truthy and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is truthy, false otherwise.\n * @signature\n * isTruthy(data)\n * @example\n * isTruthy('somethingElse') //=> true\n * isTruthy(null) //=> false\n * isTruthy(undefined) //=> false\n * isTruthy(false) //=> false\n * isTruthy(0) //=> false\n * isTruthy('') //=> false\n * @category Guard\n */\n\nexport function isTruthy<T>(\n data: T,\n): data is Exclude<T, '' | 0 | false | null | undefined> {\n return Boolean(data);\n}\n"],"mappings":"mEAiBA,SAAgB,EACd,EACuD,CACvD,MAAO,EAAQ"}
1
+ {"version":3,"file":"is-truthy.cjs","names":[],"sources":["../src/is-truthy.ts"],"sourcesContent":["/**\n * A function that checks if the passed parameter is truthy and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is truthy, false otherwise.\n * @signature\n * isTruthy(data)\n * @example\n * isTruthy('somethingElse') //=> true\n * isTruthy(null) //=> false\n * isTruthy(undefined) //=> false\n * isTruthy(false) //=> false\n * isTruthy(0) //=> false\n * isTruthy('') //=> false\n * @category Guard\n */\n\nexport function isTruthy<T>(\n data: T,\n): data is Exclude<T, '' | 0 | false | null | undefined> {\n return Boolean(data);\n}\n"],"mappings":"mEAiBA,SAAgB,EACd,EACuD,CACvD,MAAO,EAAQ,CACjB"}
@@ -1 +1 @@
1
- {"version":3,"file":"is-truthy.js","names":[],"sources":["../src/is-truthy.ts"],"sourcesContent":["/**\n * A function that checks if the passed parameter is truthy and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is truthy, false otherwise.\n * @signature\n * isTruthy(data)\n * @example\n * isTruthy('somethingElse') //=> true\n * isTruthy(null) //=> false\n * isTruthy(undefined) //=> false\n * isTruthy(false) //=> false\n * isTruthy(0) //=> false\n * isTruthy('') //=> false\n * @category Guard\n */\n\nexport function isTruthy<T>(\n data: T,\n): data is Exclude<T, '' | 0 | false | null | undefined> {\n return Boolean(data);\n}\n"],"mappings":"AAiBA,SAAgB,EACd,EACuD,CACvD,MAAO,EAAQ"}
1
+ {"version":3,"file":"is-truthy.js","names":[],"sources":["../src/is-truthy.ts"],"sourcesContent":["/**\n * A function that checks if the passed parameter is truthy and narrows its type accordingly.\n *\n * @param data - The variable to check.\n * @returns True if the passed input is truthy, false otherwise.\n * @signature\n * isTruthy(data)\n * @example\n * isTruthy('somethingElse') //=> true\n * isTruthy(null) //=> false\n * isTruthy(undefined) //=> false\n * isTruthy(false) //=> false\n * isTruthy(0) //=> false\n * isTruthy('') //=> false\n * @category Guard\n */\n\nexport function isTruthy<T>(\n data: T,\n): data is Exclude<T, '' | 0 | false | null | undefined> {\n return Boolean(data);\n}\n"],"mappings":"AAiBA,SAAgB,EACd,EACuD,CACvD,MAAO,EAAQ,CACjB"}
package/dist/join.cjs CHANGED
@@ -1,2 +1,2 @@
1
- Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require(`./curry.cjs`);function t(...t){return e.curry(n,t)}function n(e,t){return e.join(t)}exports.join=t;
1
+ Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./curry.cjs");function t(...t){return e.curry(n,t)}function n(e,t){return e.join(t)}exports.join=t;
2
2
  //# sourceMappingURL=join.cjs.map
package/dist/join.cjs.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"join.cjs","names":["curry"],"sources":["../src/join.ts"],"sourcesContent":["import type { Join } from 'type-fest';\nimport { curry } from './curry';\n\n// Copied from type-fest, from the Join type.\ntype JoinableItem = bigint | boolean | number | string | null | undefined;\n\n/**\n * Joins the elements of the array by: casting them to a string and\n * concatenating them one to the other, with the provided glue string in between\n * every two elements.\n *\n * When called on a tuple and with stricter item types (union of literal values,\n * the result is strictly typed to the tuples shape and it's item types).\n *\n * @param data - The array to join.\n * @param glue - The string to put in between every two elements.\n * @signature\n * join(data, glue)\n * @example\n * join([1,2,3], \",\") // => \"1,2,3\" (typed `string`)\n * join(['a','b','c'], \"\") // => \"abc\" (typed `string`)\n * join(['hello', 'world'] as const, \" \") // => \"hello world\" (typed `hello world`)\n * @dataFirst\n * @category Array\n */\nexport function join<\n T extends ReadonlyArray<JoinableItem> | [],\n Glue extends string,\n>(data: T, glue: Glue): Join<T, Glue>;\n\n/**\n * Joins the elements of the array by: casting them to a string and\n * concatenating them one to the other, with the provided glue string in between\n * every two elements.\n *\n * When called on a tuple and with stricter item types (union of literal values,\n * the result is strictly typed to the tuples shape and it's item types).\n *\n * @param glue - The string to put in between every two elements.\n * @signature\n * join(glue)(data)\n * @example\n * pipe([1,2,3], join(\",\")) // => \"1,2,3\" (typed `string`)\n * pipe(['a','b','c'], join(\"\")) // => \"abc\" (typed `string`)\n * pipe(['hello', 'world'] as const, join(\" \")) // => \"hello world\" (typed `hello world`)\n * @dataLast\n * @category Array\n */\nexport function join<\n T extends ReadonlyArray<JoinableItem> | [],\n Glue extends string,\n>(glue: Glue): (data: T) => Join<T, Glue>;\n\nexport function join(...args: ReadonlyArray<unknown>): unknown {\n return curry(joinImplementation, args);\n}\n\nfunction joinImplementation(data: ReadonlyArray<unknown>, glue: string): string {\n return data.join(glue);\n}\n"],"mappings":"kGAqDA,SAAgB,EAAK,GAAG,EAAuC,CAC7D,OAAOA,EAAAA,MAAM,EAAoB,EAAK,CAGxC,SAAS,EAAmB,EAA8B,EAAsB,CAC9E,OAAO,EAAK,KAAK,EAAK"}
1
+ {"version":3,"file":"join.cjs","names":["curry"],"sources":["../src/join.ts"],"sourcesContent":["import type { Join } from 'type-fest';\nimport { curry } from './curry';\n\n// Copied from type-fest, from the Join type.\ntype JoinableItem = bigint | boolean | number | string | null | undefined;\n\n/**\n * Joins the elements of the array by: casting them to a string and\n * concatenating them one to the other, with the provided glue string in between\n * every two elements.\n *\n * When called on a tuple and with stricter item types (union of literal values,\n * the result is strictly typed to the tuples shape and it's item types).\n *\n * @param data - The array to join.\n * @param glue - The string to put in between every two elements.\n * @signature\n * join(data, glue)\n * @example\n * join([1,2,3], \",\") // => \"1,2,3\" (typed `string`)\n * join(['a','b','c'], \"\") // => \"abc\" (typed `string`)\n * join(['hello', 'world'] as const, \" \") // => \"hello world\" (typed `hello world`)\n * @dataFirst\n * @category Array\n */\nexport function join<\n T extends ReadonlyArray<JoinableItem> | [],\n Glue extends string,\n>(data: T, glue: Glue): Join<T, Glue>;\n\n/**\n * Joins the elements of the array by: casting them to a string and\n * concatenating them one to the other, with the provided glue string in between\n * every two elements.\n *\n * When called on a tuple and with stricter item types (union of literal values,\n * the result is strictly typed to the tuples shape and it's item types).\n *\n * @param glue - The string to put in between every two elements.\n * @signature\n * join(glue)(data)\n * @example\n * pipe([1,2,3], join(\",\")) // => \"1,2,3\" (typed `string`)\n * pipe(['a','b','c'], join(\"\")) // => \"abc\" (typed `string`)\n * pipe(['hello', 'world'] as const, join(\" \")) // => \"hello world\" (typed `hello world`)\n * @dataLast\n * @category Array\n */\nexport function join<\n T extends ReadonlyArray<JoinableItem> | [],\n Glue extends string,\n>(glue: Glue): (data: T) => Join<T, Glue>;\n\nexport function join(...args: ReadonlyArray<unknown>): unknown {\n return curry(joinImplementation, args);\n}\n\nfunction joinImplementation(data: ReadonlyArray<unknown>, glue: string): string {\n return data.join(glue);\n}\n"],"mappings":"kGAqDA,SAAgB,EAAK,GAAG,EAAuC,CAC7D,OAAOA,EAAAA,MAAM,EAAoB,CAAI,CACvC,CAEA,SAAS,EAAmB,EAA8B,EAAsB,CAC9E,OAAO,EAAK,KAAK,CAAI,CACvB"}
package/dist/join.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"join.js","names":[],"sources":["../src/join.ts"],"sourcesContent":["import type { Join } from 'type-fest';\nimport { curry } from './curry';\n\n// Copied from type-fest, from the Join type.\ntype JoinableItem = bigint | boolean | number | string | null | undefined;\n\n/**\n * Joins the elements of the array by: casting them to a string and\n * concatenating them one to the other, with the provided glue string in between\n * every two elements.\n *\n * When called on a tuple and with stricter item types (union of literal values,\n * the result is strictly typed to the tuples shape and it's item types).\n *\n * @param data - The array to join.\n * @param glue - The string to put in between every two elements.\n * @signature\n * join(data, glue)\n * @example\n * join([1,2,3], \",\") // => \"1,2,3\" (typed `string`)\n * join(['a','b','c'], \"\") // => \"abc\" (typed `string`)\n * join(['hello', 'world'] as const, \" \") // => \"hello world\" (typed `hello world`)\n * @dataFirst\n * @category Array\n */\nexport function join<\n T extends ReadonlyArray<JoinableItem> | [],\n Glue extends string,\n>(data: T, glue: Glue): Join<T, Glue>;\n\n/**\n * Joins the elements of the array by: casting them to a string and\n * concatenating them one to the other, with the provided glue string in between\n * every two elements.\n *\n * When called on a tuple and with stricter item types (union of literal values,\n * the result is strictly typed to the tuples shape and it's item types).\n *\n * @param glue - The string to put in between every two elements.\n * @signature\n * join(glue)(data)\n * @example\n * pipe([1,2,3], join(\",\")) // => \"1,2,3\" (typed `string`)\n * pipe(['a','b','c'], join(\"\")) // => \"abc\" (typed `string`)\n * pipe(['hello', 'world'] as const, join(\" \")) // => \"hello world\" (typed `hello world`)\n * @dataLast\n * @category Array\n */\nexport function join<\n T extends ReadonlyArray<JoinableItem> | [],\n Glue extends string,\n>(glue: Glue): (data: T) => Join<T, Glue>;\n\nexport function join(...args: ReadonlyArray<unknown>): unknown {\n return curry(joinImplementation, args);\n}\n\nfunction joinImplementation(data: ReadonlyArray<unknown>, glue: string): string {\n return data.join(glue);\n}\n"],"mappings":"mCAqDA,SAAgB,EAAK,GAAG,EAAuC,CAC7D,OAAO,EAAM,EAAoB,EAAK,CAGxC,SAAS,EAAmB,EAA8B,EAAsB,CAC9E,OAAO,EAAK,KAAK,EAAK"}
1
+ {"version":3,"file":"join.js","names":[],"sources":["../src/join.ts"],"sourcesContent":["import type { Join } from 'type-fest';\nimport { curry } from './curry';\n\n// Copied from type-fest, from the Join type.\ntype JoinableItem = bigint | boolean | number | string | null | undefined;\n\n/**\n * Joins the elements of the array by: casting them to a string and\n * concatenating them one to the other, with the provided glue string in between\n * every two elements.\n *\n * When called on a tuple and with stricter item types (union of literal values,\n * the result is strictly typed to the tuples shape and it's item types).\n *\n * @param data - The array to join.\n * @param glue - The string to put in between every two elements.\n * @signature\n * join(data, glue)\n * @example\n * join([1,2,3], \",\") // => \"1,2,3\" (typed `string`)\n * join(['a','b','c'], \"\") // => \"abc\" (typed `string`)\n * join(['hello', 'world'] as const, \" \") // => \"hello world\" (typed `hello world`)\n * @dataFirst\n * @category Array\n */\nexport function join<\n T extends ReadonlyArray<JoinableItem> | [],\n Glue extends string,\n>(data: T, glue: Glue): Join<T, Glue>;\n\n/**\n * Joins the elements of the array by: casting them to a string and\n * concatenating them one to the other, with the provided glue string in between\n * every two elements.\n *\n * When called on a tuple and with stricter item types (union of literal values,\n * the result is strictly typed to the tuples shape and it's item types).\n *\n * @param glue - The string to put in between every two elements.\n * @signature\n * join(glue)(data)\n * @example\n * pipe([1,2,3], join(\",\")) // => \"1,2,3\" (typed `string`)\n * pipe(['a','b','c'], join(\"\")) // => \"abc\" (typed `string`)\n * pipe(['hello', 'world'] as const, join(\" \")) // => \"hello world\" (typed `hello world`)\n * @dataLast\n * @category Array\n */\nexport function join<\n T extends ReadonlyArray<JoinableItem> | [],\n Glue extends string,\n>(glue: Glue): (data: T) => Join<T, Glue>;\n\nexport function join(...args: ReadonlyArray<unknown>): unknown {\n return curry(joinImplementation, args);\n}\n\nfunction joinImplementation(data: ReadonlyArray<unknown>, glue: string): string {\n return data.join(glue);\n}\n"],"mappings":"mCAqDA,SAAgB,EAAK,GAAG,EAAuC,CAC7D,OAAO,EAAM,EAAoB,CAAI,CACvC,CAEA,SAAS,EAAmB,EAA8B,EAAsB,CAC9E,OAAO,EAAK,KAAK,CAAI,CACvB"}
@@ -1 +1 @@
1
- {"version":3,"file":"key-codes.cjs","names":[],"sources":["../src/key-codes.ts"],"sourcesContent":["/**\n * Using event.code is not predictable since each machine may have different output\n */\n\nexport const KEY_CODES = {\n ALT: 'Alt',\n ARROW_DOWN: 'ArrowDown',\n ARROW_LEFT: 'ArrowLeft',\n ARROW_RIGHT: 'ArrowRight',\n ARROW_UP: 'ArrowUp',\n AT: '@',\n BACKSPACE: 'Backspace',\n CTRL: 'Control',\n DELETE: 'Delete',\n END: 'End',\n ENTER: 'Enter',\n ESC: 'Escape',\n HOME: 'Home',\n KEY_F: 'KEY_F',\n META: 'Meta',\n PAGE_DOWN: 'PageDown',\n PAGE_UP: 'PageUp',\n SHIFT: 'Shift',\n SPACE: 'Space',\n TAB: 'Tab',\n} as const;\n"],"mappings":"mEAIA,MAAa,EAAY,CACvB,IAAK,MACL,WAAY,YACZ,WAAY,YACZ,YAAa,aACb,SAAU,UACV,GAAI,IACJ,UAAW,YACX,KAAM,UACN,OAAQ,SACR,IAAK,MACL,MAAO,QACP,IAAK,SACL,KAAM,OACN,MAAO,QACP,KAAM,OACN,UAAW,WACX,QAAS,SACT,MAAO,QACP,MAAO,QACP,IAAK,MACN"}
1
+ {"version":3,"file":"key-codes.cjs","names":[],"sources":["../src/key-codes.ts"],"sourcesContent":["/**\n * Using event.code is not predictable since each machine may have different output\n */\n\nexport const KEY_CODES = {\n ALT: 'Alt',\n ARROW_DOWN: 'ArrowDown',\n ARROW_LEFT: 'ArrowLeft',\n ARROW_RIGHT: 'ArrowRight',\n ARROW_UP: 'ArrowUp',\n AT: '@',\n BACKSPACE: 'Backspace',\n CTRL: 'Control',\n DELETE: 'Delete',\n END: 'End',\n ENTER: 'Enter',\n ESC: 'Escape',\n HOME: 'Home',\n KEY_F: 'KEY_F',\n META: 'Meta',\n PAGE_DOWN: 'PageDown',\n PAGE_UP: 'PageUp',\n SHIFT: 'Shift',\n SPACE: 'Space',\n TAB: 'Tab',\n} as const;\n"],"mappings":"mEAIA,MAAa,EAAY,CACvB,IAAK,MACL,WAAY,YACZ,WAAY,YACZ,YAAa,aACb,SAAU,UACV,GAAI,IACJ,UAAW,YACX,KAAM,UACN,OAAQ,SACR,IAAK,MACL,MAAO,QACP,IAAK,SACL,KAAM,OACN,MAAO,QACP,KAAM,OACN,UAAW,WACX,QAAS,SACT,MAAO,QACP,MAAO,QACP,IAAK,KACP"}
@@ -1 +1 @@
1
- {"version":3,"file":"key-codes.js","names":[],"sources":["../src/key-codes.ts"],"sourcesContent":["/**\n * Using event.code is not predictable since each machine may have different output\n */\n\nexport const KEY_CODES = {\n ALT: 'Alt',\n ARROW_DOWN: 'ArrowDown',\n ARROW_LEFT: 'ArrowLeft',\n ARROW_RIGHT: 'ArrowRight',\n ARROW_UP: 'ArrowUp',\n AT: '@',\n BACKSPACE: 'Backspace',\n CTRL: 'Control',\n DELETE: 'Delete',\n END: 'End',\n ENTER: 'Enter',\n ESC: 'Escape',\n HOME: 'Home',\n KEY_F: 'KEY_F',\n META: 'Meta',\n PAGE_DOWN: 'PageDown',\n PAGE_UP: 'PageUp',\n SHIFT: 'Shift',\n SPACE: 'Space',\n TAB: 'Tab',\n} as const;\n"],"mappings":"AAIA,MAAa,EAAY,CACvB,IAAK,MACL,WAAY,YACZ,WAAY,YACZ,YAAa,aACb,SAAU,UACV,GAAI,IACJ,UAAW,YACX,KAAM,UACN,OAAQ,SACR,IAAK,MACL,MAAO,QACP,IAAK,SACL,KAAM,OACN,MAAO,QACP,KAAM,OACN,UAAW,WACX,QAAS,SACT,MAAO,QACP,MAAO,QACP,IAAK,MACN"}
1
+ {"version":3,"file":"key-codes.js","names":[],"sources":["../src/key-codes.ts"],"sourcesContent":["/**\n * Using event.code is not predictable since each machine may have different output\n */\n\nexport const KEY_CODES = {\n ALT: 'Alt',\n ARROW_DOWN: 'ArrowDown',\n ARROW_LEFT: 'ArrowLeft',\n ARROW_RIGHT: 'ArrowRight',\n ARROW_UP: 'ArrowUp',\n AT: '@',\n BACKSPACE: 'Backspace',\n CTRL: 'Control',\n DELETE: 'Delete',\n END: 'End',\n ENTER: 'Enter',\n ESC: 'Escape',\n HOME: 'Home',\n KEY_F: 'KEY_F',\n META: 'Meta',\n PAGE_DOWN: 'PageDown',\n PAGE_UP: 'PageUp',\n SHIFT: 'Shift',\n SPACE: 'Space',\n TAB: 'Tab',\n} as const;\n"],"mappings":"AAIA,MAAa,EAAY,CACvB,IAAK,MACL,WAAY,YACZ,WAAY,YACZ,YAAa,aACb,SAAU,UACV,GAAI,IACJ,UAAW,YACX,KAAM,UACN,OAAQ,SACR,IAAK,MACL,MAAO,QACP,IAAK,SACL,KAAM,OACN,MAAO,QACP,KAAM,OACN,UAAW,WACX,QAAS,SACT,MAAO,QACP,MAAO,QACP,IAAK,KACP"}
package/dist/keys.cjs CHANGED
@@ -1,2 +1,2 @@
1
- Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require(`./curry.cjs`);function t(...t){return e.curry(Object.keys,t)}exports.keys=t;
1
+ Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./curry.cjs");function t(...t){return e.curry(Object.keys,t)}exports.keys=t;
2
2
  //# sourceMappingURL=keys.cjs.map