@stryke/types 0.5.1 → 0.6.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 (226) hide show
  1. package/README.md +16 -14
  2. package/dist/{utility-types/array.d.ts → array.d.ts} +0 -12
  3. package/dist/{utility-types/async.d.ts → async.d.ts} +1 -11
  4. package/dist/{utility-types/base.d.ts → base.d.ts} +23 -31
  5. package/dist/index.cjs +181 -16
  6. package/dist/index.d.ts +19 -4
  7. package/dist/index.mjs +1 -1
  8. package/dist/{utility-types/json.d.ts → json.d.ts} +0 -10
  9. package/dist/{utility-types/number.d.ts → number.d.ts} +0 -22
  10. package/dist/{utility-types/object.d.ts → object.d.ts} +1 -15
  11. package/dist/{utility-types/package-json.d.ts → package-json.d.ts} +3 -5
  12. package/dist/{utility-types/string.d.ts → string.d.ts} +0 -12
  13. package/dist/{utility-types/tsconfig.d.ts → tsconfig.d.ts} +0 -2
  14. package/dist/{utility-types/utilities.d.ts → utilities.d.ts} +1 -1
  15. package/dist/validations.cjs +1 -0
  16. package/dist/validations.mjs +0 -0
  17. package/package.json +125 -987
  18. package/dist/convert/buffer-to-string.cjs +0 -8
  19. package/dist/convert/buffer-to-string.d.ts +0 -1
  20. package/dist/convert/buffer-to-string.mjs +0 -1
  21. package/dist/convert/index.cjs +0 -71
  22. package/dist/convert/index.d.ts +0 -6
  23. package/dist/convert/index.mjs +0 -1
  24. package/dist/convert/string-to-uint8-array.cjs +0 -8
  25. package/dist/convert/string-to-uint8-array.d.ts +0 -7
  26. package/dist/convert/string-to-uint8-array.mjs +0 -1
  27. package/dist/convert/to-array.cjs +0 -9
  28. package/dist/convert/to-array.d.ts +0 -8
  29. package/dist/convert/to-array.mjs +0 -1
  30. package/dist/convert/to-string-key.cjs +0 -9
  31. package/dist/convert/to-string-key.d.ts +0 -7
  32. package/dist/convert/to-string-key.mjs +0 -1
  33. package/dist/convert/uint8-array-to-string.cjs +0 -8
  34. package/dist/convert/uint8-array-to-string.d.ts +0 -13
  35. package/dist/convert/uint8-array-to-string.mjs +0 -1
  36. package/dist/convert/utf8-array-to-string.cjs +0 -8
  37. package/dist/convert/utf8-array-to-string.d.ts +0 -13
  38. package/dist/convert/utf8-array-to-string.mjs +0 -1
  39. package/dist/helpers/index.cjs +0 -16
  40. package/dist/helpers/index.d.ts +0 -1
  41. package/dist/helpers/index.mjs +0 -1
  42. package/dist/helpers/parse-type-definition.cjs +0 -33
  43. package/dist/helpers/parse-type-definition.d.ts +0 -8
  44. package/dist/helpers/parse-type-definition.mjs +0 -1
  45. package/dist/type-checks/get-object-tag.cjs +0 -8
  46. package/dist/type-checks/get-object-tag.d.ts +0 -7
  47. package/dist/type-checks/get-object-tag.mjs +0 -1
  48. package/dist/type-checks/index.cjs +0 -456
  49. package/dist/type-checks/index.d.ts +0 -41
  50. package/dist/type-checks/index.mjs +0 -1
  51. package/dist/type-checks/is-array-like.cjs +0 -11
  52. package/dist/type-checks/is-array-like.d.ts +0 -7
  53. package/dist/type-checks/is-array-like.mjs +0 -1
  54. package/dist/type-checks/is-async-iterable.cjs +0 -10
  55. package/dist/type-checks/is-async-iterable.d.ts +0 -7
  56. package/dist/type-checks/is-async-iterable.mjs +0 -1
  57. package/dist/type-checks/is-bigint.cjs +0 -9
  58. package/dist/type-checks/is-bigint.d.ts +0 -16
  59. package/dist/type-checks/is-bigint.mjs +0 -1
  60. package/dist/type-checks/is-boolean.cjs +0 -14
  61. package/dist/type-checks/is-boolean.d.ts +0 -7
  62. package/dist/type-checks/is-boolean.mjs +0 -1
  63. package/dist/type-checks/is-buffer.cjs +0 -10
  64. package/dist/type-checks/is-buffer.d.ts +0 -5
  65. package/dist/type-checks/is-buffer.mjs +0 -1
  66. package/dist/type-checks/is-collection.cjs +0 -11
  67. package/dist/type-checks/is-collection.d.ts +0 -8
  68. package/dist/type-checks/is-collection.mjs +0 -1
  69. package/dist/type-checks/is-date.cjs +0 -10
  70. package/dist/type-checks/is-date.d.ts +0 -16
  71. package/dist/type-checks/is-date.mjs +0 -1
  72. package/dist/type-checks/is-deep-key.cjs +0 -26
  73. package/dist/type-checks/is-deep-key.d.ts +0 -35
  74. package/dist/type-checks/is-deep-key.mjs +0 -1
  75. package/dist/type-checks/is-empty-object.cjs +0 -23
  76. package/dist/type-checks/is-empty-object.d.ts +0 -14
  77. package/dist/type-checks/is-empty-object.mjs +0 -1
  78. package/dist/type-checks/is-empty-string.cjs +0 -16
  79. package/dist/type-checks/is-empty-string.d.ts +0 -7
  80. package/dist/type-checks/is-empty-string.mjs +0 -1
  81. package/dist/type-checks/is-empty.cjs +0 -35
  82. package/dist/type-checks/is-empty.d.ts +0 -8
  83. package/dist/type-checks/is-empty.mjs +0 -1
  84. package/dist/type-checks/is-equal.cjs +0 -18
  85. package/dist/type-checks/is-equal.d.ts +0 -1
  86. package/dist/type-checks/is-equal.mjs +0 -1
  87. package/dist/type-checks/is-error.cjs +0 -15
  88. package/dist/type-checks/is-error.d.ts +0 -17
  89. package/dist/type-checks/is-error.mjs +0 -1
  90. package/dist/type-checks/is-file-result.cjs +0 -11
  91. package/dist/type-checks/is-file-result.d.ts +0 -8
  92. package/dist/type-checks/is-file-result.mjs +0 -1
  93. package/dist/type-checks/is-float.cjs +0 -9
  94. package/dist/type-checks/is-float.d.ts +0 -8
  95. package/dist/type-checks/is-float.mjs +0 -1
  96. package/dist/type-checks/is-function.cjs +0 -23
  97. package/dist/type-checks/is-function.d.ts +0 -10
  98. package/dist/type-checks/is-function.mjs +0 -1
  99. package/dist/type-checks/is-integer.cjs +0 -10
  100. package/dist/type-checks/is-integer.d.ts +0 -8
  101. package/dist/type-checks/is-integer.mjs +0 -1
  102. package/dist/type-checks/is-mergeable-object.cjs +0 -14
  103. package/dist/type-checks/is-mergeable-object.d.ts +0 -1
  104. package/dist/type-checks/is-mergeable-object.mjs +0 -1
  105. package/dist/type-checks/is-non-null-object.cjs +0 -10
  106. package/dist/type-checks/is-non-null-object.d.ts +0 -7
  107. package/dist/type-checks/is-non-null-object.mjs +0 -1
  108. package/dist/type-checks/is-not-empty.cjs +0 -17
  109. package/dist/type-checks/is-not-empty.d.ts +0 -7
  110. package/dist/type-checks/is-not-empty.mjs +0 -1
  111. package/dist/type-checks/is-null.cjs +0 -14
  112. package/dist/type-checks/is-null.d.ts +0 -1
  113. package/dist/type-checks/is-null.mjs +0 -1
  114. package/dist/type-checks/is-number.cjs +0 -19
  115. package/dist/type-checks/is-number.d.ts +0 -15
  116. package/dist/type-checks/is-number.mjs +0 -1
  117. package/dist/type-checks/is-object-index.cjs +0 -17
  118. package/dist/type-checks/is-object-index.d.ts +0 -7
  119. package/dist/type-checks/is-object-index.mjs +0 -1
  120. package/dist/type-checks/is-object.cjs +0 -30
  121. package/dist/type-checks/is-object.d.ts +0 -30
  122. package/dist/type-checks/is-object.mjs +0 -1
  123. package/dist/type-checks/is-plain-object.cjs +0 -17
  124. package/dist/type-checks/is-plain-object.d.ts +0 -50
  125. package/dist/type-checks/is-plain-object.mjs +0 -1
  126. package/dist/type-checks/is-primitive.cjs +0 -14
  127. package/dist/type-checks/is-primitive.d.ts +0 -1
  128. package/dist/type-checks/is-primitive.mjs +0 -1
  129. package/dist/type-checks/is-promise.cjs +0 -12
  130. package/dist/type-checks/is-promise.d.ts +0 -17
  131. package/dist/type-checks/is-promise.mjs +0 -1
  132. package/dist/type-checks/is-react-element.cjs +0 -8
  133. package/dist/type-checks/is-react-element.d.ts +0 -1
  134. package/dist/type-checks/is-react-element.mjs +0 -1
  135. package/dist/type-checks/is-ref.cjs +0 -14
  136. package/dist/type-checks/is-ref.d.ts +0 -8
  137. package/dist/type-checks/is-ref.mjs +0 -1
  138. package/dist/type-checks/is-regexp.cjs +0 -10
  139. package/dist/type-checks/is-regexp.d.ts +0 -16
  140. package/dist/type-checks/is-regexp.mjs +0 -1
  141. package/dist/type-checks/is-select-option.cjs +0 -15
  142. package/dist/type-checks/is-select-option.d.ts +0 -8
  143. package/dist/type-checks/is-select-option.mjs +0 -1
  144. package/dist/type-checks/is-set-object.cjs +0 -15
  145. package/dist/type-checks/is-set-object.d.ts +0 -7
  146. package/dist/type-checks/is-set-object.mjs +0 -1
  147. package/dist/type-checks/is-set-string.cjs +0 -16
  148. package/dist/type-checks/is-set-string.d.ts +0 -7
  149. package/dist/type-checks/is-set-string.mjs +0 -1
  150. package/dist/type-checks/is-set.cjs +0 -15
  151. package/dist/type-checks/is-set.d.ts +0 -7
  152. package/dist/type-checks/is-set.mjs +0 -1
  153. package/dist/type-checks/is-string.cjs +0 -14
  154. package/dist/type-checks/is-string.d.ts +0 -1
  155. package/dist/type-checks/is-string.mjs +0 -1
  156. package/dist/type-checks/is-symbol.cjs +0 -14
  157. package/dist/type-checks/is-symbol.d.ts +0 -1
  158. package/dist/type-checks/is-symbol.mjs +0 -1
  159. package/dist/type-checks/is-typed-array.cjs +0 -9
  160. package/dist/type-checks/is-typed-array.d.ts +0 -1
  161. package/dist/type-checks/is-typed-array.mjs +0 -1
  162. package/dist/type-checks/is-typed.cjs +0 -16
  163. package/dist/type-checks/is-typed.d.ts +0 -8
  164. package/dist/type-checks/is-typed.mjs +0 -1
  165. package/dist/type-checks/is-undefined.cjs +0 -8
  166. package/dist/type-checks/is-undefined.d.ts +0 -1
  167. package/dist/type-checks/is-undefined.mjs +0 -1
  168. package/dist/type-checks/property-exists.cjs +0 -17
  169. package/dist/type-checks/property-exists.d.ts +0 -16
  170. package/dist/type-checks/property-exists.mjs +0 -1
  171. package/dist/type-checks/type-detect.cjs +0 -38
  172. package/dist/type-checks/type-detect.d.ts +0 -1
  173. package/dist/type-checks/type-detect.mjs +0 -1
  174. package/dist/utility-types/array.cjs +0 -9
  175. package/dist/utility-types/array.mjs +0 -1
  176. package/dist/utility-types/index.cjs +0 -214
  177. package/dist/utility-types/index.d.ts +0 -19
  178. package/dist/utility-types/index.mjs +0 -1
  179. /package/dist/{utility-types/async.cjs → array.cjs} +0 -0
  180. /package/dist/{utility-types/async.mjs → array.mjs} +0 -0
  181. /package/dist/{utility-types/configuration.cjs → async.cjs} +0 -0
  182. /package/dist/{utility-types/configuration.mjs → async.mjs} +0 -0
  183. /package/dist/{utility-types/base.cjs → base.cjs} +0 -0
  184. /package/dist/{utility-types/base.mjs → base.mjs} +0 -0
  185. /package/dist/{utility-types/form.cjs → configuration.cjs} +0 -0
  186. /package/dist/{utility-types/configuration.d.ts → configuration.d.ts} +0 -0
  187. /package/dist/{utility-types/form.mjs → configuration.mjs} +0 -0
  188. /package/dist/{utility-types/file.cjs → file.cjs} +0 -0
  189. /package/dist/{utility-types/file.d.ts → file.d.ts} +0 -0
  190. /package/dist/{utility-types/file.mjs → file.mjs} +0 -0
  191. /package/dist/{utility-types/json.cjs → form.cjs} +0 -0
  192. /package/dist/{utility-types/form.d.ts → form.d.ts} +0 -0
  193. /package/dist/{utility-types/json.mjs → form.mjs} +0 -0
  194. /package/dist/{utility-types/logic.cjs → json.cjs} +0 -0
  195. /package/dist/{utility-types/logic.mjs → json.mjs} +0 -0
  196. /package/dist/{utility-types/navigator.cjs → logic.cjs} +0 -0
  197. /package/dist/{utility-types/logic.d.ts → logic.d.ts} +0 -0
  198. /package/dist/{utility-types/navigator.mjs → logic.mjs} +0 -0
  199. /package/dist/{utility-types/messages.cjs → messages.cjs} +0 -0
  200. /package/dist/{utility-types/messages.d.ts → messages.d.ts} +0 -0
  201. /package/dist/{utility-types/messages.mjs → messages.mjs} +0 -0
  202. /package/dist/{utility-types/number.cjs → navigator.cjs} +0 -0
  203. /package/dist/{utility-types/navigator.d.ts → navigator.d.ts} +0 -0
  204. /package/dist/{utility-types/number.mjs → navigator.mjs} +0 -0
  205. /package/dist/{utility-types/object.cjs → number.cjs} +0 -0
  206. /package/dist/{utility-types/object.mjs → number.mjs} +0 -0
  207. /package/dist/{utility-types/package-json.cjs → object.cjs} +0 -0
  208. /package/dist/{utility-types/package-json.mjs → object.mjs} +0 -0
  209. /package/dist/{utility-types/string.cjs → package-json.cjs} +0 -0
  210. /package/dist/{utility-types/string.mjs → package-json.mjs} +0 -0
  211. /package/dist/{utility-types/package-manager.cjs → package-manager.cjs} +0 -0
  212. /package/dist/{utility-types/package-manager.d.ts → package-manager.d.ts} +0 -0
  213. /package/dist/{utility-types/package-manager.mjs → package-manager.mjs} +0 -0
  214. /package/dist/{utility-types/system.cjs → string.cjs} +0 -0
  215. /package/dist/{utility-types/system.mjs → string.mjs} +0 -0
  216. /package/dist/{utility-types/tsconfig.cjs → system.cjs} +0 -0
  217. /package/dist/{utility-types/system.d.ts → system.d.ts} +0 -0
  218. /package/dist/{utility-types/tsconfig.mjs → system.mjs} +0 -0
  219. /package/dist/{utility-types/utilities.cjs → tsconfig.cjs} +0 -0
  220. /package/dist/{utility-types/utilities.mjs → tsconfig.mjs} +0 -0
  221. /package/dist/{utility-types/user.cjs → user.cjs} +0 -0
  222. /package/dist/{utility-types/user.d.ts → user.d.ts} +0 -0
  223. /package/dist/{utility-types/user.mjs → user.mjs} +0 -0
  224. /package/dist/{utility-types/validations.cjs → utilities.cjs} +0 -0
  225. /package/dist/{utility-types/validations.mjs → utilities.mjs} +0 -0
  226. /package/dist/{utility-types/validations.d.ts → validations.d.ts} +0 -0
@@ -1,8 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.bufferToString = void 0;
7
- const bufferToString = t => t.toString("utf8");
8
- exports.bufferToString = bufferToString;
@@ -1 +0,0 @@
1
- export declare const bufferToString: (buf: Buffer) => string;
@@ -1 +0,0 @@
1
- export const bufferToString=t=>t.toString("utf8");
@@ -1,71 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- var _bufferToString = require("./buffer-to-string.cjs");
7
- Object.keys(_bufferToString).forEach(function (key) {
8
- if (key === "default" || key === "__esModule") return;
9
- if (key in exports && exports[key] === _bufferToString[key]) return;
10
- Object.defineProperty(exports, key, {
11
- enumerable: true,
12
- get: function () {
13
- return _bufferToString[key];
14
- }
15
- });
16
- });
17
- var _stringToUint8Array = require("./string-to-uint8-array.cjs");
18
- Object.keys(_stringToUint8Array).forEach(function (key) {
19
- if (key === "default" || key === "__esModule") return;
20
- if (key in exports && exports[key] === _stringToUint8Array[key]) return;
21
- Object.defineProperty(exports, key, {
22
- enumerable: true,
23
- get: function () {
24
- return _stringToUint8Array[key];
25
- }
26
- });
27
- });
28
- var _toArray = require("./to-array.cjs");
29
- Object.keys(_toArray).forEach(function (key) {
30
- if (key === "default" || key === "__esModule") return;
31
- if (key in exports && exports[key] === _toArray[key]) return;
32
- Object.defineProperty(exports, key, {
33
- enumerable: true,
34
- get: function () {
35
- return _toArray[key];
36
- }
37
- });
38
- });
39
- var _toStringKey = require("./to-string-key.cjs");
40
- Object.keys(_toStringKey).forEach(function (key) {
41
- if (key === "default" || key === "__esModule") return;
42
- if (key in exports && exports[key] === _toStringKey[key]) return;
43
- Object.defineProperty(exports, key, {
44
- enumerable: true,
45
- get: function () {
46
- return _toStringKey[key];
47
- }
48
- });
49
- });
50
- var _uint8ArrayToString = require("./uint8-array-to-string.cjs");
51
- Object.keys(_uint8ArrayToString).forEach(function (key) {
52
- if (key === "default" || key === "__esModule") return;
53
- if (key in exports && exports[key] === _uint8ArrayToString[key]) return;
54
- Object.defineProperty(exports, key, {
55
- enumerable: true,
56
- get: function () {
57
- return _uint8ArrayToString[key];
58
- }
59
- });
60
- });
61
- var _utf8ArrayToString = require("./utf8-array-to-string.cjs");
62
- Object.keys(_utf8ArrayToString).forEach(function (key) {
63
- if (key === "default" || key === "__esModule") return;
64
- if (key in exports && exports[key] === _utf8ArrayToString[key]) return;
65
- Object.defineProperty(exports, key, {
66
- enumerable: true,
67
- get: function () {
68
- return _utf8ArrayToString[key];
69
- }
70
- });
71
- });
@@ -1,6 +0,0 @@
1
- export * from "./buffer-to-string";
2
- export * from "./string-to-uint8-array";
3
- export * from "./to-array";
4
- export * from "./to-string-key";
5
- export * from "./uint8-array-to-string";
6
- export * from "./utf8-array-to-string";
@@ -1 +0,0 @@
1
- export*from"./buffer-to-string";export*from"./string-to-uint8-array";export*from"./to-array";export*from"./to-string-key";export*from"./uint8-array-to-string";export*from"./utf8-array-to-string";
@@ -1,8 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.stringToUint8Array = void 0;
7
- const stringToUint8Array = n => Uint8Array.from([...encodeURIComponent(n)].map(r => r.codePointAt(0)));
8
- exports.stringToUint8Array = stringToUint8Array;
@@ -1,7 +0,0 @@
1
- /**
2
- * Convert a string to Uint8Array
3
- *
4
- * @param text - The text to convert
5
- * @returns The converted Uint8Array
6
- */
7
- export declare const stringToUint8Array: (text: string) => Uint8Array;
@@ -1 +0,0 @@
1
- export const stringToUint8Array=n=>Uint8Array.from([...encodeURIComponent(n)].map(r=>r.codePointAt(0)));
@@ -1,9 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.toArray = toArray;
7
- function toArray(t) {
8
- return t = t ?? [], Array.isArray(t) ? t : [t];
9
- }
@@ -1,8 +0,0 @@
1
- import type { Arrayable } from "../utility-types/array";
2
- import type { Nullable } from "../utility-types/utilities";
3
- /**
4
- * Convert `Arrayable<T>` to `Array<T>`
5
- *
6
- * @category Array
7
- */
8
- export declare function toArray<T>(array?: Nullable<Arrayable<T>>): Array<T>;
@@ -1 +0,0 @@
1
- export function toArray(t){return t=t??[],Array.isArray(t)?t:[t]}
@@ -1,9 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.toStringKey = toStringKey;
7
- function toStringKey(t) {
8
- return Object.is(t, -0) ? "-0" : t.toString();
9
- }
@@ -1,7 +0,0 @@
1
- /**
2
- * Converts `value` to a string key if it's not a string or symbol.
3
- *
4
- * @param value - The value to inspect.
5
- * @returns Returns the key.
6
- */
7
- export declare function toStringKey(value: number): string | symbol;
@@ -1 +0,0 @@
1
- export function toStringKey(t){return Object.is(t,-0)?"-0":t.toString()}
@@ -1,8 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.uint8ArrayToString = void 0;
7
- const uint8ArrayToString = r => decodeURIComponent(Buffer.from(r).toString("utf8"));
8
- exports.uint8ArrayToString = uint8ArrayToString;
@@ -1,13 +0,0 @@
1
- /**
2
- * Convert a utf8 array to string
3
- *
4
- * @remarks
5
- * This method is part of the {@linkcode Convert} namespace.
6
- *
7
- * @credits https://stackoverflow.com/a/41798356/1465919
8
- * @credits https://stackoverflow.com/a/36949791/1465919
9
- *
10
- * @param array - Utf-8 Array
11
- * @returns The converted string
12
- */
13
- export declare const uint8ArrayToString: (arr: Uint8Array) => string;
@@ -1 +0,0 @@
1
- export const uint8ArrayToString=r=>decodeURIComponent(Buffer.from(r).toString("utf8"));
@@ -1,8 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.utf8ArrayToString = void 0;
7
- const utf8ArrayToString = r => new TextDecoder().decode(r);
8
- exports.utf8ArrayToString = utf8ArrayToString;
@@ -1,13 +0,0 @@
1
- /**
2
- * Convert a utf8 array to string
3
- *
4
- * @remarks
5
- * This method is part of the {@linkcode Convert} namespace.
6
- *
7
- * @credits https://stackoverflow.com/a/41798356/1465919
8
- * @credits https://stackoverflow.com/a/36949791/1465919
9
- *
10
- * @param array - Utf-8 Array
11
- * @returns The converted string
12
- */
13
- export declare const utf8ArrayToString: (array: Uint8Array) => string;
@@ -1 +0,0 @@
1
- export const utf8ArrayToString=r=>new TextDecoder().decode(r);
@@ -1,16 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- var _parseTypeDefinition = require("./parse-type-definition.cjs");
7
- Object.keys(_parseTypeDefinition).forEach(function (key) {
8
- if (key === "default" || key === "__esModule") return;
9
- if (key in exports && exports[key] === _parseTypeDefinition[key]) return;
10
- Object.defineProperty(exports, key, {
11
- enumerable: true,
12
- get: function () {
13
- return _parseTypeDefinition[key];
14
- }
15
- });
16
- });
@@ -1 +0,0 @@
1
- export * from "./parse-type-definition";
@@ -1 +0,0 @@
1
- export*from"./parse-type-definition";
@@ -1,33 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.parseTypeDefinition = void 0;
7
- var _typeChecks = require("../type-checks/index.cjs");
8
- const parseTypeDefinition = e => {
9
- if ((0, _typeChecks.isString)(e)) {
10
- if (e.includes(":")) {
11
- const i = e.split(":");
12
- if (i.length > 1 && i[0]) return {
13
- file: i[0],
14
- name: i[1]
15
- };
16
- }
17
- if (e.includes("#")) {
18
- const i = e.split("#");
19
- if (i.length > 1 && i[0]) return {
20
- file: i[0],
21
- name: i[1]
22
- };
23
- }
24
- return {
25
- file: e
26
- };
27
- }
28
- if ((0, _typeChecks.isObject)(e)) return {
29
- file: e.file,
30
- name: e.name
31
- };
32
- };
33
- exports.parseTypeDefinition = parseTypeDefinition;
@@ -1,8 +0,0 @@
1
- import type { TypeDefinition, TypeDefinitionParameter } from "../utility-types/configuration";
2
- /**
3
- * Parse a type definition parameter into a {@link TypeDefinition} object
4
- *
5
- * @param param - The parameter to parse
6
- * @returns The parsed type definition
7
- */
8
- export declare const parseTypeDefinition: (param: TypeDefinitionParameter) => TypeDefinition | undefined;
@@ -1 +0,0 @@
1
- import{isObject as n,isString as t}from"../type-checks";export const parseTypeDefinition=e=>{if(t(e)){if(e.includes(":")){const i=e.split(":");if(i.length>1&&i[0])return{file:i[0],name:i[1]}}if(e.includes("#")){const i=e.split("#");if(i.length>1&&i[0])return{file:i[0],name:i[1]}}return{file:e}}if(n(e))return{file:e.file,name:e.name}};
@@ -1,8 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.getObjectTag = void 0;
7
- const getObjectTag = t => t == null ? t === void 0 ? "[object Undefined]" : "[object Null]" : Object.prototype.toString.call(t);
8
- exports.getObjectTag = getObjectTag;
@@ -1,7 +0,0 @@
1
- /**
2
- * Gets the `toStringTag` of `obj`.
3
- *
4
- * @param value - The obj to query.
5
- * @returns Returns the `toStringTag`.
6
- */
7
- export declare const getObjectTag: (value: unknown) => string;
@@ -1 +0,0 @@
1
- export const getObjectTag=t=>t==null?t===void 0?"[object Undefined]":"[object Null]":Object.prototype.toString.call(t);