@rzl-zone/utils-js 3.1.3-beta.0 → 3.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (210) hide show
  1. package/README.md +48 -32
  2. package/dist/NumberRangeUnion-B6bhM2s7.d.ts +33 -0
  3. package/dist/{any-BmdI8UbK.d.ts → any-v4TsK9ES.d.ts} +25 -26
  4. package/dist/{arrays-normalize-recursive-CnjYJ9xg.d.ts → arrays-normalize-recursive-BqmVuFlD.d.ts} +20 -20
  5. package/dist/assertions/index.cjs +1 -1
  6. package/dist/assertions/index.d.ts +96 -70
  7. package/dist/assertions/index.js +1 -1
  8. package/dist/chunk-2CQX5CBG.js +1 -0
  9. package/dist/chunk-2IOOEY45.cjs +1 -0
  10. package/dist/chunk-3IBQ5MOM.js +1 -0
  11. package/dist/chunk-3VA554KW.js +1 -0
  12. package/dist/chunk-5757UBXJ.cjs +1 -0
  13. package/dist/chunk-5IGC6PBH.js +1 -0
  14. package/dist/chunk-5KJFVIQT.cjs +1 -0
  15. package/dist/chunk-6JFCSH7J.js +1 -0
  16. package/dist/chunk-6JFZL7YE.cjs +1 -0
  17. package/dist/chunk-7ODAAXX5.cjs +1 -0
  18. package/dist/chunk-BAV5T2E3.cjs +1 -0
  19. package/dist/chunk-CAH33WOQ.cjs +1 -0
  20. package/dist/chunk-CKTLUNWX.js +1 -0
  21. package/dist/chunk-CMW2TBOQ.js +1 -0
  22. package/dist/chunk-D3ENH7H6.cjs +1 -0
  23. package/dist/chunk-DEZZUYE2.js +1 -0
  24. package/dist/chunk-DVMHRLKP.cjs +1 -0
  25. package/dist/chunk-DWF2R5GD.cjs +1 -0
  26. package/dist/chunk-E55EQK2U.cjs +1 -0
  27. package/dist/chunk-E74U6CYP.cjs +1 -0
  28. package/dist/chunk-EL6A35UR.cjs +1 -0
  29. package/dist/chunk-F6IPNNSJ.cjs +1 -0
  30. package/dist/chunk-FJZGG54N.cjs +1 -0
  31. package/dist/chunk-FWCKOJZM.js +1 -0
  32. package/dist/chunk-FWHNWL2P.cjs +1 -0
  33. package/dist/chunk-GGEADHZO.js +1 -0
  34. package/dist/chunk-GQR4R5WY.js +1 -0
  35. package/dist/chunk-H66AC7GK.cjs +1 -0
  36. package/dist/chunk-HQWOFR56.cjs +1 -0
  37. package/dist/chunk-HYRQMTRH.cjs +1 -0
  38. package/dist/chunk-IRFL4MAX.js +1 -0
  39. package/dist/chunk-IVL7CKVH.cjs +1 -0
  40. package/dist/chunk-IZPBKKPO.js +1 -0
  41. package/dist/chunk-JBQMXC5I.cjs +1 -0
  42. package/dist/chunk-JEQEF5WD.js +1 -0
  43. package/dist/chunk-JMJQCN74.js +1 -0
  44. package/dist/chunk-JYQTCICM.js +1 -0
  45. package/dist/chunk-KHO2SBNA.cjs +1 -0
  46. package/dist/chunk-KVAL5PAG.cjs +1 -0
  47. package/dist/chunk-L5RDAVVH.js +1 -0
  48. package/dist/chunk-LS6U7FAY.cjs +1 -0
  49. package/dist/chunk-NBZWMBO6.js +1 -0
  50. package/dist/chunk-NRF6LWBC.cjs +1 -0
  51. package/dist/chunk-OI5XKNZO.js +1 -0
  52. package/dist/chunk-ONZFBJVW.js +1 -0
  53. package/dist/chunk-OYTYSY7G.js +1 -0
  54. package/dist/chunk-PET42Z7W.js +1 -0
  55. package/dist/chunk-PZQ6I4JJ.cjs +1 -0
  56. package/dist/chunk-QBKAEVYG.js +1 -0
  57. package/dist/chunk-QNKGP5DY.js +1 -0
  58. package/dist/chunk-RIPKY4RU.js +1 -0
  59. package/dist/chunk-RZW35UN5.cjs +1 -0
  60. package/dist/chunk-SBFNXGTJ.js +1 -0
  61. package/dist/chunk-SBKGWRS5.js +1 -0
  62. package/dist/chunk-SIM77PU4.js +1 -0
  63. package/dist/chunk-T2T7K3KR.js +1 -0
  64. package/dist/chunk-T7PU2V7X.cjs +1 -0
  65. package/dist/chunk-UDA26MCU.cjs +1 -0
  66. package/dist/chunk-V45XJKHW.cjs +1 -0
  67. package/dist/chunk-VJDDGRIK.cjs +1 -0
  68. package/dist/chunk-W2WNBUDE.js +1 -0
  69. package/dist/chunk-WVSPXFTY.js +1 -0
  70. package/dist/chunk-XABCB3Y7.cjs +1 -0
  71. package/dist/chunk-XEDXFSGI.js +1 -0
  72. package/dist/chunk-YKPSRP5G.js +1 -0
  73. package/dist/chunk-YLA3DURS.cjs +1 -0
  74. package/dist/chunk-YWHHVDT4.js +1 -0
  75. package/dist/chunk-ZETAZZLD.cjs +1 -0
  76. package/dist/conversions/index.cjs +1 -1
  77. package/dist/conversions/index.d.ts +515 -321
  78. package/dist/conversions/index.js +1 -1
  79. package/dist/events/index.cjs +1 -1
  80. package/dist/events/index.d.ts +25 -20
  81. package/dist/events/index.js +1 -1
  82. package/dist/{extends-Bk_SBGdT.d.ts → extends-DtdRjDyU.d.ts} +63 -87
  83. package/dist/formatters/index.cjs +1 -0
  84. package/dist/formatters/index.d.ts +2106 -0
  85. package/dist/formatters/index.js +1 -0
  86. package/dist/generators/index.cjs +1 -0
  87. package/dist/{generator → generators}/index.d.ts +57 -59
  88. package/dist/generators/index.js +1 -0
  89. package/dist/{if-CvT4R7Kh.d.ts → if-ChM35c_q.d.ts} +6 -5
  90. package/dist/{is-array--YjXV-Wx.d.ts → is-array-BJeHxPM3.d.ts} +287 -542
  91. package/dist/{isPlainObject-BVhBAPHX.d.ts → isPlainObject-DGJkcFYw.d.ts} +6 -6
  92. package/dist/{never-BfayMBF9.d.ts → never-D89PbPh5.d.ts} +10 -19
  93. package/dist/next/index.cjs +1 -8
  94. package/dist/next/index.d.ts +15 -12
  95. package/dist/next/index.js +1 -8
  96. package/dist/next/server/index.cjs +1 -2
  97. package/dist/next/server/index.d.ts +1 -1
  98. package/dist/next/server/index.js +1 -2
  99. package/dist/{nils-DMz3kU7M.d.ts → nils-CO8zLHSB.d.ts} +39 -65
  100. package/dist/operations/index.cjs +1 -1
  101. package/dist/operations/index.d.ts +4 -4
  102. package/dist/operations/index.js +1 -1
  103. package/dist/or-C6qzKt2I.d.ts +82 -0
  104. package/dist/override-CL2olHE5.d.ts +59 -0
  105. package/dist/parsers/index.cjs +1 -1
  106. package/dist/parsers/index.js +1 -1
  107. package/dist/pick-BSMX6Xe2.d.ts +15 -0
  108. package/dist/predicates/index.cjs +1 -1
  109. package/dist/predicates/index.d.ts +425 -106
  110. package/dist/predicates/index.js +1 -1
  111. package/dist/prettify-3o8_Kw6b.d.ts +564 -0
  112. package/dist/promises/index.cjs +1 -0
  113. package/dist/promises/index.d.ts +107 -0
  114. package/dist/promises/index.js +1 -0
  115. package/dist/promises-LU7K00H0.d.ts +72 -0
  116. package/dist/rzl-utils.global.js +1 -4
  117. package/dist/{string-XA-til3C.d.ts → string-B1jlOnws.d.ts} +82 -121
  118. package/dist/strings/index.cjs +1 -1
  119. package/dist/strings/index.d.ts +209 -210
  120. package/dist/strings/index.js +1 -1
  121. package/dist/tailwind/index.cjs +1 -0
  122. package/dist/tailwind/index.d.ts +571 -0
  123. package/dist/tailwind/index.js +1 -0
  124. package/dist/types/index.d.ts +899 -1181
  125. package/dist/urls/index.cjs +1 -1
  126. package/dist/urls/index.d.ts +113 -108
  127. package/dist/urls/index.js +1 -1
  128. package/package.json +45 -47
  129. package/dist/NumberRangeUnion-DC-C3_Kq.d.ts +0 -26
  130. package/dist/chunk-26W3VZIK.cjs +0 -1
  131. package/dist/chunk-2KRCHXFG.cjs +0 -2
  132. package/dist/chunk-33ZLH266.js +0 -1
  133. package/dist/chunk-4L4EJTNZ.js +0 -1
  134. package/dist/chunk-56QBKKRE.js +0 -1
  135. package/dist/chunk-5Q37AP7P.js +0 -1
  136. package/dist/chunk-5SZUSNGZ.js +0 -1
  137. package/dist/chunk-7CHFAMS2.js +0 -1
  138. package/dist/chunk-7MMJZ6HS.js +0 -1
  139. package/dist/chunk-7TC6DE3J.cjs +0 -1
  140. package/dist/chunk-7VX33E3V.js +0 -1
  141. package/dist/chunk-7YWAQOA4.cjs +0 -1
  142. package/dist/chunk-BEZPD44N.cjs +0 -1
  143. package/dist/chunk-BI263OHW.js +0 -1
  144. package/dist/chunk-CII6WWLO.cjs +0 -1
  145. package/dist/chunk-D5TYPCWU.cjs +0 -1
  146. package/dist/chunk-EEQY5QUG.js +0 -1
  147. package/dist/chunk-ELDDNERR.js +0 -1
  148. package/dist/chunk-ESJYBIYH.js +0 -1
  149. package/dist/chunk-EWYPSKKM.js +0 -1
  150. package/dist/chunk-EXCOQLWX.cjs +0 -1
  151. package/dist/chunk-FIEZKTAZ.cjs +0 -1
  152. package/dist/chunk-FWQVTMYA.cjs +0 -1
  153. package/dist/chunk-G4EWCRKS.js +0 -1
  154. package/dist/chunk-G5LXIEFO.js +0 -0
  155. package/dist/chunk-G7R5XZRM.cjs +0 -1
  156. package/dist/chunk-GGEV7LXX.cjs +0 -1
  157. package/dist/chunk-HJOZOENU.cjs +0 -1
  158. package/dist/chunk-IRDZVLNZ.cjs +0 -1
  159. package/dist/chunk-IW73G523.cjs +0 -1
  160. package/dist/chunk-IY5OZAB3.cjs +0 -1
  161. package/dist/chunk-J4NCYYGS.js +0 -1
  162. package/dist/chunk-J7JAZAJD.js +0 -1
  163. package/dist/chunk-JYNSO7ZY.js +0 -1
  164. package/dist/chunk-K3UVKYEU.js +0 -1
  165. package/dist/chunk-LQ76EDZG.js +0 -1
  166. package/dist/chunk-MMSYCIJ2.cjs +0 -1
  167. package/dist/chunk-MROH35V3.cjs +0 -1
  168. package/dist/chunk-NJSAV73S.js +0 -1
  169. package/dist/chunk-NNM7QCNB.js +0 -1
  170. package/dist/chunk-NR44SNYE.js +0 -1
  171. package/dist/chunk-NXMTWY77.js +0 -1
  172. package/dist/chunk-OZCQZO2V.cjs +0 -4
  173. package/dist/chunk-PUQXRLZH.cjs +0 -1
  174. package/dist/chunk-Q3NTKN5I.cjs +0 -1
  175. package/dist/chunk-QDNSC57Z.js +0 -4
  176. package/dist/chunk-QGXTL5ZH.js +0 -2
  177. package/dist/chunk-QSQDP7L2.cjs +0 -1
  178. package/dist/chunk-RV2VULM7.cjs +0 -1
  179. package/dist/chunk-S5M33A4O.js +0 -1
  180. package/dist/chunk-SGTHOQQ2.js +0 -1
  181. package/dist/chunk-SL3RQOWA.js +0 -1
  182. package/dist/chunk-SW6HYEW7.cjs +0 -1
  183. package/dist/chunk-SYJC7UAW.js +0 -1
  184. package/dist/chunk-SZPWZZYG.cjs +0 -1
  185. package/dist/chunk-UA4B7JBO.cjs +0 -1
  186. package/dist/chunk-UQDJF5RR.cjs +0 -1
  187. package/dist/chunk-UTQUYABU.cjs +0 -1
  188. package/dist/chunk-VPW3DRV5.js +0 -1
  189. package/dist/chunk-W32WALNU.js +0 -1
  190. package/dist/chunk-XGZ6K753.cjs +0 -1
  191. package/dist/chunk-YFTR64N5.cjs +0 -1
  192. package/dist/chunk-ZFDS7W6B.cjs +0 -1
  193. package/dist/chunk-ZQOLZE6Z.cjs +0 -1
  194. package/dist/env/index.cjs +0 -1
  195. package/dist/env/index.d.ts +0 -16
  196. package/dist/env/index.js +0 -1
  197. package/dist/formatting/index.cjs +0 -1
  198. package/dist/formatting/index.d.ts +0 -950
  199. package/dist/formatting/index.js +0 -1
  200. package/dist/generator/index.cjs +0 -1
  201. package/dist/generator/index.js +0 -1
  202. package/dist/omit-VvmIsZmX.d.ts +0 -28
  203. package/dist/prettify-C4xLcYOP.d.ts +0 -353
  204. package/dist/promise/index.cjs +0 -1
  205. package/dist/promise/index.d.ts +0 -31
  206. package/dist/promise/index.js +0 -1
  207. package/dist/stylings/index.cjs +0 -1
  208. package/dist/stylings/index.d.ts +0 -41
  209. package/dist/stylings/index.js +0 -1
  210. package/dist/type-data-DDs-u2kq.d.ts +0 -261
package/README.md CHANGED
@@ -3,21 +3,37 @@
3
3
  </div>
4
4
 
5
5
  <p align="center">
6
- 🚀 <strong>Rzl Utility JavaScript</strong> 🚀<br/>
6
+ 🚀 <strong>Rzl Utility JS</strong> 🚀<br/>
7
7
  A lightweight, modern TypeScript utility library for Node.js & browser (via bundlers like Webpack/Vite).<br/>
8
- Provides reusable helpers to simplify your JavaScript / TypeScript projects.<br/>
9
- <strong>Built with ❤️ by <a href="https://github.com/rzl-app">@rzl-app</a>.</strong>
8
+ Provides reusable helpers to simplify your JavaScript or TypeScript projects.<br/>
9
+ <strong>Built with ❤️ by <a href="https://github.com/rzl-app" target="_blank" rel="nofollow noreferrer noopener">@rzl-app</a>.</strong>
10
10
  </p>
11
11
 
12
12
  <div align="center">
13
13
 
14
- [![Latest Version on NPM](https://img.shields.io/npm/v/@rzl-zone/utils-js?color=blue&style=flat-rounded)](https://npmjs.com/package/@rzl-zone/utils-js)
15
- [![downloads](https://img.shields.io/npm/dt/@rzl-zone/utils-js?style=flat-rounded)](https://npmjs.com/package/@rzl-zone/utils-js)
16
- [![Node.js](https://img.shields.io/badge/node-%3E%3D16.0.0%20%7C%20%3E%3D18.17.0-blue.svg?logo=node.js&style=flat-rounded)](https://nodejs.org/en/)
17
- [![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg)](https://github.com/rzl-zone/utils-js/blob/main/CONTRIBUTING.md)
18
- [![GitHub license](https://img.shields.io/badge/license-MIT-blue.svg)](https://github.com/rzl-zone/utils-js/blob/main/LICENSE.md)
19
- [![GitHub](https://img.shields.io/badge/GitHub-rzl--zone%2Futils--js-181717?logo=github)](https://github.com/rzl-zone/utils-js)
20
- [![Repo on GitHub](https://img.shields.io/badge/Repo-on%20GitHub-181717?logo=github&style=flat-rounded)](https://github.com/rzl-app)
14
+ <p>
15
+ <a href="https://npmjs.com/package/@rzl-zone/utils-js" target="_blank" rel="nofollow noreferrer noopener">
16
+ <img src="https://img.shields.io/npm/v/@rzl-zone/utils-js?color=blue&style=flat-rounded" alt="Latest Version on NPM" data-canonical-src="https://img.shields.io/npm/v/@rzl-zone/utils-js?color=blue&amp;style=flat-rounded">
17
+ </a>
18
+ <a href="https://npmjs.com/package/@rzl-zone/utils-js" target="_blank" rel="nofollow noreferrer noopener">
19
+ <img src="https://img.shields.io/npm/dt/@rzl-zone/utils-js?style=flat-rounded" alt="Downloads">
20
+ </a>
21
+ <a href="https://nodejs.org/en/" target="_blank" rel="nofollow noreferrer noopener">
22
+ <img src="https://img.shields.io/badge/node-≥16.0.0-blue.svg?logo=node.js&style=flat-rounded" alt="Node.js">
23
+ </a>
24
+ <a href="https://github.com/rzl-zone/utils-js/blob/main/CONTRIBUTING.md" target="_blank" rel="nofollow noreferrer noopener">
25
+ <img src="https://img.shields.io/badge/PRs-welcome-brightgreen.svg" alt="PRs Welcome">
26
+ </a>
27
+ <a href="https://github.com/rzl-zone/utils-js/blob/main/LICENSE.md" target="_blank" rel="nofollow noreferrer noopener">
28
+ <img src="https://img.shields.io/badge/license-MIT-blue.svg" alt="GitHub license">
29
+ </a>
30
+ <a href="https://github.com/rzl-zone/utils-js" target="_blank" rel="nofollow noreferrer noopener">
31
+ <img src="https://img.shields.io/badge/GitHub-rzl--zone%2Futils--js-181717?logo=github" alt="GitHub">
32
+ </a>
33
+ <a href="https://github.com/rzl-app" target="_blank" rel="nofollow noreferrer noopener">
34
+ <img src="https://img.shields.io/badge/Repo-on%20GitHub-181717?logo=github&style=flat-rounded" alt="Repo on GitHub">
35
+ </a>
36
+ </p>
21
37
 
22
38
  </div>
23
39
 
@@ -34,7 +50,7 @@ Provides reusable helpers to simplify your JavaScript / TypeScript projects.<br/
34
50
  - ❤️ [Sponsor](#sponsor-this-package)
35
51
  - 📜 [Changelog](#changelog)
36
52
  - 🤝 [Contributing](#contributing)
37
- - 🛡 [Security](#security)
53
+ - 🔒 [Security](#security)
38
54
  - 🙌 [Credits](#credits)
39
55
  - 📄 [License](#license)
40
56
 
@@ -42,12 +58,14 @@ Provides reusable helpers to simplify your JavaScript / TypeScript projects.<br/
42
58
 
43
59
  <h2 id="requirements">💻 Requirements</h2>
44
60
 
45
- - **Node.js >= 16.0.0 or >=18.17.0**
46
- This package leverages modern JavaScript & TypeScript features that require Node.js version 16.0.0 if not using nextjs and 18.17.0 or higher for nextjs.
61
+ - **Node.js `≥16.0.0`**
62
+ This package leverages modern JavaScript & TypeScript features that require Node.js version 16.0.0 if not using Next.js, and for Next.js it must follow the official minimum Node.js version requirement depending on the version you use.
63
+ - 🔗 See official Next.js documentation:
64
+ <a href="https://nextjs.org/docs/getting-started/installation#system-requirements" target="_blank" rel="nofollow noreferrer noopener">NextJS Installation Requirements</a>
47
65
 
48
66
  - Works with:
49
67
  - ✅ Node.js (16.0.0+) - Without NextJS
50
- - ✅ Node.js (18.17.0+) - With NextJS
68
+ - ✅ Node.js (18.17.0, or higher depending on NextJS version) - With NextJS
51
69
  - ✅ Modern browsers (via bundlers like Webpack / Vite)
52
70
 
53
71
  ---
@@ -81,7 +99,7 @@ Provides reusable helpers to simplify your JavaScript / TypeScript projects.<br/
81
99
  - 📦 Works in **Node.js** & modern browsers
82
100
  - ❤️ Simple API, easy to extend
83
101
  - 🧬 **Next.js support**: helpers for dynamic routes, building URLs, reading env, extracting client IP
84
- - 🛠 Additional TypeScript types: `OmitStrict`, `PartialByKeys`, etc.
102
+ - 🛠 Additional TypeScript types: `OmitStrict`, `PartialOnly`, etc.
85
103
 
86
104
  ---
87
105
 
@@ -109,30 +127,28 @@ This package also provides utilities specially built for Next.js environments, n
109
127
 
110
128
  <h2 id="detailed-features">💎 Detailed Features</h2>
111
129
 
112
- ### Full documentation coming soon.
113
- #### For now, explore the examples or dive into the source — all utilities are documented via **JSDoc** and typed properly.
130
+ ### Full documentation <a href="https://docs-rzl-utils-js.vercel.app" target="_blank" rel="nofollow noreferrer noopener">Rzl UtilsJS</a> is **currently under construction** 🏗️.
131
+ #### For now, explore the examples or dive into the source — all utilities are documented via **TSDoc** and typed properly.
114
132
 
115
133
  ```ts
116
134
  import { | } from "@rzl-zone/utils-js/assertions";
117
- import { | } from "@rzl-zone/utils-js/conversions";
118
- import { | } from "@rzl-zone/utils-js/env";
135
+ import { | } from "@rzl-zone/utils-js/conversions";
119
136
  import { | } from "@rzl-zone/utils-js/events";
120
- import { | } from "@rzl-zone/utils-js/formatting";
121
- import { | } from "@rzl-zone/utils-js/generator";
122
- import { | } from "@rzl-zone/utils-js/generator";
137
+ import { | } from "@rzl-zone/utils-js/formatters";
138
+ import { | } from "@rzl-zone/utils-js/generators";
123
139
  import { | } from "@rzl-zone/utils-js/next";
124
140
  import { | } from "@rzl-zone/utils-js/next/server";
125
141
  import { | } from "@rzl-zone/utils-js/operations";
126
142
  import { | } from "@rzl-zone/utils-js/parsers";
127
143
  import { | } from "@rzl-zone/utils-js/predicates";
128
- import { | } from "@rzl-zone/utils-js/promise";
144
+ import { | } from "@rzl-zone/utils-js/promises";
129
145
  import { | } from "@rzl-zone/utils-js/strings";
130
- import { | } from "@rzl-zone/utils-js/stylings";
146
+ import { | } from "@rzl-zone/utils-js/tailwind";
131
147
  import { | } from "@rzl-zone/utils-js/urls";
132
148
 
133
149
  import type { | } from "@rzl-zone/utils-js/types";
134
150
  ```
135
- #### Just place your cursor right inside `{ }` or from after import from `"@rzl-zone/utils-js/"` like the pipe ("|") above then ctrl + space, there are many functions or types and then hover to each function is complete with how to use it because I have added jsDoc.
151
+ #### Just place your cursor right inside `{ }` or after import from `"@rzl-zone/utils-js/{{ | }}"` like the pipe ("|") above then ctrl + space, there are many functions or types and then hover to each function is complete with how to use it because I have added tsDoc.
136
152
 
137
153
  <!-- - <h4 id="detailed-features--assertions">
138
154
  Assertions -
@@ -159,23 +175,23 @@ This package also provides utilities specially built for Next.js environments, n
159
175
 
160
176
  <h2 id="usage">🔥 Usage</h2>
161
177
 
162
- #### Easy to use, just import on your code base.
178
+ ### Easy to use, just import on your code base.
163
179
 
164
- ##### Example Function Import:
180
+ #### Example Function Import:
165
181
 
166
182
  ```ts
167
- import { isServer } from "@rzl-zone/utils-js/env";
183
+ import { isServer } from "@rzl-zone/utils-js/predicates";
168
184
 
169
185
  console.log(isServer());
170
- // true if running on Node.js, false if browser
186
+ // ➔ `true` if running on server-side, `false` if in browser.
171
187
  ```
172
188
 
173
- ##### Example TypeScript Helper Import:
189
+ #### Example Types Helper Import:
174
190
 
175
191
  ```ts
176
192
  import type { OmitStrict } from "@rzl-zone/utils-js/types";
177
193
 
178
- type MyType = OmitStrict<OtherType, "omitedProps">;
194
+ type MyType = OmitStrict<OtherType, "omittingProps">;
179
195
  // Fully strict TS omit that requires all keys to exist in target
180
196
  ```
181
197
 
@@ -200,7 +216,7 @@ See [CONTRIBUTING](CONTRIBUTING.md).
200
216
 
201
217
  ---
202
218
 
203
- <h2 id="security">🛡 Security</h2>
219
+ <h2 id="security">🔒 Security</h2>
204
220
 
205
221
  Please report issues to [rizalvindwiky1998@gmail.com](mailto:rizalvindwiky1998@gmail.com).
206
222
 
@@ -0,0 +1,33 @@
1
+ /** --------------------------------------------------
2
+ * * ***Internal Utility Type for: {@link NumberRangeUnion | `NumberRangeUnion`}.***
3
+ * --------------------------------------------------
4
+ * @template N - Starting/Ending number of the range (inclusive).
5
+ * @template Acc - Internal accumulator for recursion (do not set manually).
6
+ */
7
+ type Enumerate<N extends number,Acc extends number[]=[]>=Acc["length"] extends N?Acc[number]:Enumerate<N,[...Acc,Acc["length"]]>;
8
+ /** --------------------------------------------------
9
+ * * ***Utility Type: `NumberRangeUnion`.***
10
+ * --------------------------------------------------
11
+ * **Generate a union type of numbers from `From` to `To` using enumeration.**
12
+ * @description
13
+ * Produces a **numeric union type** from `From` to `To` (inclusive),
14
+ * using a simpler approach based on `Enumerate<N>` helper type.
15
+ * - ✅ Straightforward & easy to reason about.
16
+ * - ⚠️ Still limited by TypeScript recursion depth (safe up to `999`).
17
+ * - ⚙️ Best used for **smaller ranges** (`≤ 100`) or when readability matters.
18
+ * - ℹ️ For **larger ranges** (`≥ 101`) use {@link NumberRangeLimit | `NumberRangeLimit`} instead.
19
+ * @template From - Starting number of the range (inclusive).
20
+ * @template To - Ending number of the range (inclusive).
21
+ * @example
22
+ * ```ts
23
+ * type RangeA = NumberRangeUnion<3, 6>;
24
+ * // ➔ 3 | 4 | 5 | 6
25
+ * type RangeB = NumberRangeUnion<0, 2>;
26
+ * // ➔ 0 | 1 | 2
27
+ * type RangeC = NumberRangeUnion<8, 8>;
28
+ * // ➔ 8
29
+ * type RangeD = NumberRangeUnion<20, 10>;
30
+ * // ➔ 10
31
+ * ```
32
+ */
33
+ type NumberRangeUnion<From extends number,To extends number>=From extends To?From:Exclude<Enumerate<To>,Enumerate<From>>extends never?To:Exclude<Enumerate<To>,Enumerate<From>>|To;export type{NumberRangeUnion as N};
@@ -1,11 +1,11 @@
1
- import{I as If}from'./if-CvT4R7Kh.js';
1
+ import{I as If}from'./if-ChM35c_q.js';
2
2
  /** -------------------------------------------------------
3
- * * ***IsAny.***
3
+ * * ***Utility Type: `IsAny`.***
4
4
  * -------------------------------------------------------
5
- * A type-level utility that checks whether a type is ***`any`***.
6
- * - Returns `true` if `T` is `any`.
7
- * - Returns `false` otherwise.
8
- *
5
+ * **A type-level utility that checks whether a type is ***`any`***.**
6
+ * - **Behavior:**
7
+ * - Returns `true` if `T` is `any`.
8
+ * - Returns `false` for otherwise.
9
9
  * @template T - The type to evaluate.
10
10
  * @example
11
11
  * ```ts
@@ -17,18 +17,16 @@ import{I as If}from'./if-CvT4R7Kh.js';
17
17
  */
18
18
  type IsAny<T>=0 extends 1 & T?true:false;
19
19
  /** -------------------------------------------------------
20
- * * ***IfAny.***
20
+ * * ***Utility Type: `IfAny`.***
21
21
  * -------------------------------------------------------
22
- *
23
- * A type-level conditional utility that returns one type if ***`T` is `any`***,
24
- * and another type otherwise.
25
- * - Defaults to `true` when `T` is `any`.
26
- * - Defaults to `false` otherwise.
27
- *
22
+ * **A type-level conditional utility that returns one type if ***`T` is `any`***,
23
+ * and another type otherwise.**
24
+ * - **Behavior:**
25
+ * - Defaults to `true` when `T` is `any`.
26
+ * - Defaults to `false` for otherwise.
28
27
  * @template T - The type to check.
29
- * @template IfTrue - The type to return if `T` is `any`. *(default: `true`)*
30
- * @template IfFalse - The type to return if `T` is not `any`. *(default: `false`)*
31
- *
28
+ * @template IfTrue - The type to return if `T` is `any`, *(default: `true`)*.
29
+ * @template IfFalse - The type to return if `T` is not `any`, *(default: `false`)*.
32
30
  * @example
33
31
  * ```ts
34
32
  * type A = IfAny<any, string, number>;
@@ -38,7 +36,9 @@ type IsAny<T>=0 extends 1 & T?true:false;
38
36
  * ```
39
37
  */
40
38
  type IfAny<T,IfTrue=true,IfFalse=false>=If<IsAny<T>,IfTrue,IfFalse>;
41
- /** Configuration options for a type-level utility `AnifyProperties`. */
39
+ /** * ***Configuration options for a type-level utility for
40
+ * {@link AnifyProperties | `AnifyProperties`}.***
41
+ */
42
42
  type AnifyPropertiesOptions={
43
43
  /** If `makeOptional: true`, all properties become optional, otherwise, all properties are required and typed as `any`, defaultValue: `false`.
44
44
  *
@@ -46,20 +46,19 @@ type AnifyPropertiesOptions={
46
46
  */
47
47
  makeOptional:boolean;};
48
48
  /** -------------------------------------------------------
49
- * * ***AnifyProperties.***
49
+ * * ***Utility Type: `AnifyProperties`.***
50
50
  * -------------------------------------------------------
51
- *
52
- * A type-level utility that transforms all properties of an object into ***`any`***.
53
- * - If `makeOptional: true`, all properties become optional.
54
- * - Otherwise, all properties are required and typed as `any`.
55
- *
56
- * @template T - The object type to transform.
57
- * @template Options - Configuration options. Defaults to `{ makeOptional: false }`.
51
+ * **A type-level utility that transforms all properties of an object
52
+ * into ***`any`***.**
53
+ * - **Behavior:**
54
+ * - If `makeOptional: true`, all properties become optional.
55
+ * - Otherwise, all properties are required and typed as `any`.
56
+ * @template T The object type to transform.
57
+ * @template Options Configuration options, defaults to `{ makeOptional: false }`.
58
58
  * @example
59
59
  * ```ts
60
60
  * type A = AnifyProperties<{a: string; b: number}>;
61
61
  * // ➔ { a: any; b: any }
62
- *
63
62
  * type B = AnifyProperties<{a: string; b: number}, { makeOptional: true }>;
64
63
  * // ➔ { a?: any; b?: any }
65
64
  * ```
@@ -1,11 +1,11 @@
1
1
  /** -------------------------------------------------------
2
- * * ***FixNeverArrayRecursive.***
2
+ * * ***Utility Type: `FixNeverArrayRecursive`.***
3
3
  * -------------------------------------------------------
4
- * A type-level utility that **recursively transforms arrays of type `never[]` into empty arrays**.
5
- * - Preserves `readonly` modifiers.
6
- * - Applies recursively for nested arrays.
7
- * - Leaves other types unchanged.
8
- *
4
+ * **A type-level utility that **recursively transforms arrays of type `never[]` into empty arrays**.**
5
+ * - **Behavior:**
6
+ * - Preserves `readonly` modifiers.
7
+ * - Applies recursively for nested arrays.
8
+ * - Leaves other types unchanged.
9
9
  * @template T - The input type to recursively fix.
10
10
  * @example
11
11
  * ```ts
@@ -23,13 +23,13 @@
23
23
  */
24
24
  type FixNeverArrayRecursive<T>=T extends readonly never[]?T extends never[]?[]:readonly []:T extends(infer U)[]?FixNeverArrayRecursive<U>[]:T extends readonly(infer U)[]?readonly FixNeverArrayRecursive<U>[]:T;
25
25
  /** -------------------------------------------------------
26
- * * ***NormalizeEmptyArraysRecursive.***
26
+ * * ***Utility Type: `NormalizeEmptyArraysRecursive`.***
27
27
  * -------------------------------------------------------
28
- * A type-level utility that **recursively normalizes empty array types** by converting arrays whose element type is `never`, `null`, or `undefined` into empty tuple types (`[]`).
29
- * - Preserves `readonly` modifiers.
30
- * - Recurses into nested arrays.
31
- * - Leaves other array types unchanged.
32
- *
28
+ * **A type-level utility that **recursively normalizes empty array types** by converting arrays whose element type is `never`, `null`, or `undefined` into empty tuple types (`[]`).**
29
+ * - **Behavior:**
30
+ * - Preserves `readonly` modifiers.
31
+ * - Recurses into nested arrays.
32
+ * - Leaves other array types unchanged.
33
33
  * @template T - The input type to normalize.
34
34
  * @example
35
35
  * ```ts
@@ -47,15 +47,15 @@ type FixNeverArrayRecursive<T>=T extends readonly never[]?T extends never[]?[]:r
47
47
  */
48
48
  type NormalizeEmptyArraysRecursive<T>=T extends readonly(infer U)[]?U extends never|null|undefined?T extends readonly unknown[]?T extends(infer E)[]?[]:readonly []:never:T extends(infer E)[]?NormalizeEmptyArraysRecursive<U>[]:readonly NormalizeEmptyArraysRecursive<U>[]:T;
49
49
  /** -------------------------------------------------------
50
- * * ***RemoveEmptyArrayElements.***
50
+ * * ***Utility Type: `RemoveEmptyArrayElements`.***
51
51
  * -------------------------------------------------------
52
- * A type-level utility that **recursively removes empty array elements (`[]`) from a tuple type**.
53
- * - If `T` is a tuple, checks the first element:
54
- * - If `Head` is an empty array type (`[]`), it is removed.
55
- * - Otherwise, `Head` is preserved.
56
- * - Repeats recursively on the rest of the tuple.
57
- * - Leaves non-tuple types unchanged.
58
- *
52
+ * **A type-level utility that **recursively removes empty array elements (`[]`) from a tuple type**.**
53
+ * - **Behavior:**
54
+ * - If `T` is a tuple, checks the first element:
55
+ * - If `Head` is an empty array type (`[]`), it is removed.
56
+ * - Otherwise, `Head` is preserved.
57
+ * - Repeats recursively on the rest of the tuple.
58
+ * - Leaves non-tuple types unchanged.
59
59
  * @template T - The tuple type to process.
60
60
  * @example
61
61
  * ```ts
@@ -1 +1 @@
1
- 'use strict';var chunkIY5OZAB3_cjs=require('../chunk-IY5OZAB3.cjs'),chunkUQDJF5RR_cjs=require('../chunk-UQDJF5RR.cjs'),chunkBEZPD44N_cjs=require('../chunk-BEZPD44N.cjs');require('../chunk-7YWAQOA4.cjs');var chunkCII6WWLO_cjs=require('../chunk-CII6WWLO.cjs');Object.defineProperty(exports,"assertIsBigInt",{enumerable:true,get:function(){return chunkIY5OZAB3_cjs.a}});Object.defineProperty(exports,"assertIsNumber",{enumerable:true,get:function(){return chunkIY5OZAB3_cjs.b}});Object.defineProperty(exports,"assertIsArray",{enumerable:true,get:function(){return chunkUQDJF5RR_cjs.a}});Object.defineProperty(exports,"assertIsString",{enumerable:true,get:function(){return chunkBEZPD44N_cjs.a}});Object.defineProperty(exports,"assertIsBoolean",{enumerable:true,get:function(){return chunkCII6WWLO_cjs.G}});Object.defineProperty(exports,"assertIsPlainObject",{enumerable:true,get:function(){return chunkCII6WWLO_cjs.j}});
1
+ "use strict";var e=require("../chunk-IVL7CKVH.cjs"),r=require("../chunk-HYRQMTRH.cjs"),t=require("../chunk-6JFZL7YE.cjs");require("../chunk-UDA26MCU.cjs");var s=require("../chunk-PZQ6I4JJ.cjs");Object.defineProperty(exports,"assertIsBigInt",{enumerable:!0,get:function(){return e.assertIsBigInt}}),Object.defineProperty(exports,"assertIsNumber",{enumerable:!0,get:function(){return e.assertIsNumber}}),Object.defineProperty(exports,"assertIsString",{enumerable:!0,get:function(){return r.assertIsString}}),Object.defineProperty(exports,"assertIsArray",{enumerable:!0,get:function(){return t.assertIsArray}}),Object.defineProperty(exports,"assertIsBoolean",{enumerable:!0,get:function(){return s.assertIsBoolean}}),Object.defineProperty(exports,"assertIsPlainObject",{enumerable:!0,get:function(){return s.assertIsPlainObject}});