@stryke/helpers 0.10.13 → 0.10.14

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 (125) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/dist/deep-clone.cjs +3 -5
  3. package/dist/deep-clone.mjs +1 -3
  4. package/dist/deep-clone.mjs.map +1 -1
  5. package/dist/deep-merge.cjs +6 -6
  6. package/dist/deep-merge.mjs +3 -3
  7. package/dist/filter-empty.cjs +2 -2
  8. package/dist/filter-empty.mjs +1 -1
  9. package/dist/flatten-object.cjs +2 -3
  10. package/dist/flatten-object.d.cts +1 -1
  11. package/dist/flatten-object.d.mts +1 -1
  12. package/dist/flatten-object.mjs +1 -2
  13. package/dist/flatten-object.mjs.map +1 -1
  14. package/dist/get-field.cjs +4 -7
  15. package/dist/get-field.mjs +2 -5
  16. package/dist/get-field.mjs.map +1 -1
  17. package/dist/is-equal.cjs +4 -4
  18. package/dist/is-equal.mjs +2 -2
  19. package/dist/set-field.cjs +4 -4
  20. package/dist/set-field.d.cts +1 -1
  21. package/dist/set-field.d.mts +1 -1
  22. package/dist/set-field.mjs +2 -2
  23. package/dist/to-deep-key.cjs +4 -4
  24. package/dist/to-deep-key.mjs +2 -2
  25. package/dist/unflatten-object.d.cts +1 -1
  26. package/dist/unflatten-object.d.mts +1 -1
  27. package/package.json +7 -118
  28. package/dist/convert/src/index.cjs +0 -5
  29. package/dist/convert/src/index.mjs +0 -7
  30. package/dist/convert/src/parse-type-definition.cjs +0 -1
  31. package/dist/convert/src/parse-type-definition.mjs +0 -3
  32. package/dist/convert/src/string-to-utf8-array.cjs +0 -5
  33. package/dist/convert/src/string-to-utf8-array.mjs +0 -6
  34. package/dist/convert/src/string-to-utf8-array.mjs.map +0 -1
  35. package/dist/convert/src/to-bool.cjs +0 -1
  36. package/dist/convert/src/to-bool.mjs +0 -3
  37. package/dist/convert/src/to-string-key.cjs +0 -15
  38. package/dist/convert/src/to-string-key.mjs +0 -15
  39. package/dist/convert/src/to-string-key.mjs.map +0 -1
  40. package/dist/convert/src/utf8-array-to-string.cjs +0 -5
  41. package/dist/convert/src/utf8-array-to-string.mjs +0 -6
  42. package/dist/convert/src/utf8-array-to-string.mjs.map +0 -1
  43. package/dist/type-checks/src/get-object-tag.cjs +0 -15
  44. package/dist/type-checks/src/get-object-tag.mjs +0 -15
  45. package/dist/type-checks/src/get-object-tag.mjs.map +0 -1
  46. package/dist/type-checks/src/index.cjs +0 -21
  47. package/dist/type-checks/src/index.mjs +0 -23
  48. package/dist/type-checks/src/is-buffer.cjs +0 -13
  49. package/dist/type-checks/src/is-buffer.mjs +0 -14
  50. package/dist/type-checks/src/is-buffer.mjs.map +0 -1
  51. package/dist/type-checks/src/is-collection.cjs +0 -1
  52. package/dist/type-checks/src/is-collection.mjs +0 -3
  53. package/dist/type-checks/src/is-deep-key.cjs +0 -29
  54. package/dist/type-checks/src/is-deep-key.mjs +0 -29
  55. package/dist/type-checks/src/is-deep-key.mjs.map +0 -1
  56. package/dist/type-checks/src/is-empty.cjs +0 -20
  57. package/dist/type-checks/src/is-empty.mjs +0 -21
  58. package/dist/type-checks/src/is-empty.mjs.map +0 -1
  59. package/dist/type-checks/src/is-function.cjs +0 -27
  60. package/dist/type-checks/src/is-function.mjs +0 -26
  61. package/dist/type-checks/src/is-function.mjs.map +0 -1
  62. package/dist/type-checks/src/is-mergeable-object.cjs +0 -14
  63. package/dist/type-checks/src/is-mergeable-object.mjs +0 -15
  64. package/dist/type-checks/src/is-mergeable-object.mjs.map +0 -1
  65. package/dist/type-checks/src/is-non-null-object.cjs +0 -16
  66. package/dist/type-checks/src/is-non-null-object.mjs +0 -17
  67. package/dist/type-checks/src/is-non-null-object.mjs.map +0 -1
  68. package/dist/type-checks/src/is-null.cjs +0 -12
  69. package/dist/type-checks/src/is-null.mjs +0 -12
  70. package/dist/type-checks/src/is-null.mjs.map +0 -1
  71. package/dist/type-checks/src/is-number.cjs +0 -18
  72. package/dist/type-checks/src/is-number.mjs +0 -18
  73. package/dist/type-checks/src/is-number.mjs.map +0 -1
  74. package/dist/type-checks/src/is-object-index.cjs +0 -20
  75. package/dist/type-checks/src/is-object-index.mjs +0 -20
  76. package/dist/type-checks/src/is-object-index.mjs.map +0 -1
  77. package/dist/type-checks/src/is-object.cjs +0 -19
  78. package/dist/type-checks/src/is-object.mjs +0 -20
  79. package/dist/type-checks/src/is-object.mjs.map +0 -1
  80. package/dist/type-checks/src/is-plain-object.cjs +0 -64
  81. package/dist/type-checks/src/is-plain-object.mjs +0 -64
  82. package/dist/type-checks/src/is-plain-object.mjs.map +0 -1
  83. package/dist/type-checks/src/is-primitive.cjs +0 -12
  84. package/dist/type-checks/src/is-primitive.mjs +0 -12
  85. package/dist/type-checks/src/is-primitive.mjs.map +0 -1
  86. package/dist/type-checks/src/is-react-element.cjs +0 -8
  87. package/dist/type-checks/src/is-react-element.mjs +0 -8
  88. package/dist/type-checks/src/is-react-element.mjs.map +0 -1
  89. package/dist/type-checks/src/is-set-string.cjs +0 -20
  90. package/dist/type-checks/src/is-set-string.mjs +0 -21
  91. package/dist/type-checks/src/is-set-string.mjs.map +0 -1
  92. package/dist/type-checks/src/is-set.cjs +0 -19
  93. package/dist/type-checks/src/is-set.mjs +0 -20
  94. package/dist/type-checks/src/is-set.mjs.map +0 -1
  95. package/dist/type-checks/src/is-string.cjs +0 -12
  96. package/dist/type-checks/src/is-string.mjs +0 -12
  97. package/dist/type-checks/src/is-string.mjs.map +0 -1
  98. package/dist/type-checks/src/is-typed-array.cjs +0 -8
  99. package/dist/type-checks/src/is-typed-array.mjs +0 -8
  100. package/dist/type-checks/src/is-typed-array.mjs.map +0 -1
  101. package/dist/type-checks/src/is-undefined.cjs +0 -8
  102. package/dist/type-checks/src/is-undefined.mjs +0 -8
  103. package/dist/type-checks/src/is-undefined.mjs.map +0 -1
  104. package/dist/type-checks/src/property-exists.cjs +0 -31
  105. package/dist/type-checks/src/property-exists.mjs +0 -31
  106. package/dist/type-checks/src/property-exists.mjs.map +0 -1
  107. package/dist/type-checks/src/type-detect.cjs +0 -15
  108. package/dist/type-checks/src/type-detect.mjs +0 -17
  109. package/dist/type-checks/src/type-detect.mjs.map +0 -1
  110. package/dist/types/src/base.d.cts +0 -7
  111. package/dist/types/src/base.d.cts.map +0 -1
  112. package/dist/types/src/base.d.mts +0 -7
  113. package/dist/types/src/base.d.mts.map +0 -1
  114. package/dist/types/src/json.d.cts +0 -27
  115. package/dist/types/src/json.d.cts.map +0 -1
  116. package/dist/types/src/json.d.mts +0 -27
  117. package/dist/types/src/json.d.mts.map +0 -1
  118. package/dist/types/src/object.d.cts +0 -124
  119. package/dist/types/src/object.d.cts.map +0 -1
  120. package/dist/types/src/object.d.mts +0 -124
  121. package/dist/types/src/object.d.mts.map +0 -1
  122. package/dist/types/src/string.d.cts +0 -5
  123. package/dist/types/src/string.d.cts.map +0 -1
  124. package/dist/types/src/string.d.mts +0 -5
  125. package/dist/types/src/string.d.mts.map +0 -1
@@ -1,31 +0,0 @@
1
- import { isObject } from "./is-object.mjs";
2
-
3
- //#region ../type-checks/src/property-exists.ts
4
- /**
5
- * Check if the provided object has the provided property
6
- *
7
- * @param object - The object to check
8
- * @param propertyKey - The property to check
9
- * @returns An indicator specifying if the object has the provided property
10
- */
11
- const propertyExists = (object, propertyKey) => {
12
- try {
13
- return isObject(object) && propertyKey in object;
14
- } catch {
15
- return false;
16
- }
17
- };
18
- /**
19
- * Check if the provided object has the provided property and if it's safe to merge
20
- *
21
- * @param object - The object to check
22
- * @param propertyKey - The property to check
23
- * @returns An indicator specifying if the object has the provided property and if it's safe to merge
24
- */
25
- const propertyUnsafe = (object, propertyKey) => {
26
- return propertyExists(object, propertyKey) && !(Object.hasOwnProperty.call(object, propertyKey) && Object.propertyIsEnumerable.call(object, propertyKey));
27
- };
28
-
29
- //#endregion
30
- export { propertyExists, propertyUnsafe };
31
- //# sourceMappingURL=property-exists.mjs.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"property-exists.mjs","names":[],"sources":["../../../../type-checks/src/property-exists.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Stryke\n\n This code was released as part of the Stryke project. Stryke\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/stryke.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/stryke\n Documentation: https://docs.stormsoftware.com/projects/stryke\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { isObject } from \"./is-object\";\n\n/**\n * Check if the provided object has the provided property\n *\n * @param object - The object to check\n * @param propertyKey - The property to check\n * @returns An indicator specifying if the object has the provided property\n */\nexport const propertyExists = (object: any, propertyKey: PropertyKey) => {\n try {\n return isObject(object) && propertyKey in object;\n } catch {\n return false;\n }\n};\n\n/**\n * Check if the provided object has the provided property and if it's safe to merge\n *\n * @param object - The object to check\n * @param propertyKey - The property to check\n * @returns An indicator specifying if the object has the provided property and if it's safe to merge\n */\nexport const propertyUnsafe = (object: any, propertyKey: PropertyKey) => {\n return (\n propertyExists(object, propertyKey) && // Properties are safe to merge if they don't exist in the target yet,\n !(\n Object.hasOwnProperty.call(object, propertyKey) && // unsafe if they exist up the prototype chain,\n Object.propertyIsEnumerable.call(object, propertyKey)\n )\n ); // and also unsafe if they're non-enumerable.\n};\n"],"mappings":";;;;;;;;;;AA2BA,MAAa,kBAAkB,QAAa,gBAA6B;AACvE,KAAI;AACF,SAAO,SAAS,OAAO,IAAI,eAAe;SACpC;AACN,SAAO;;;;;;;;;;AAWX,MAAa,kBAAkB,QAAa,gBAA6B;AACvE,QACE,eAAe,QAAQ,YAAY,IACnC,EACE,OAAO,eAAe,KAAK,QAAQ,YAAY,IAC/C,OAAO,qBAAqB,KAAK,QAAQ,YAAY"}
@@ -1,15 +0,0 @@
1
- require('./is-buffer.cjs');
2
-
3
- //#region ../type-checks/src/type-detect.ts
4
- const globalObject = ((obj) => {
5
- if (typeof globalThis === "object") return globalThis;
6
- Object.defineProperty(obj, "typeDetectGlobalObject", {
7
- get() {
8
- return this;
9
- },
10
- configurable: true
11
- });
12
- return globalThis;
13
- })(Object.prototype);
14
-
15
- //#endregion
@@ -1,17 +0,0 @@
1
- import "./is-buffer.mjs";
2
-
3
- //#region ../type-checks/src/type-detect.ts
4
- const globalObject = ((obj) => {
5
- if (typeof globalThis === "object") return globalThis;
6
- Object.defineProperty(obj, "typeDetectGlobalObject", {
7
- get() {
8
- return this;
9
- },
10
- configurable: true
11
- });
12
- return globalThis;
13
- })(Object.prototype);
14
-
15
- //#endregion
16
- export { };
17
- //# sourceMappingURL=type-detect.mjs.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"type-detect.mjs","names":[],"sources":["../../../../type-checks/src/type-detect.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Stryke\n\n This code was released as part of the Stryke project. Stryke\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/stryke.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/stryke\n Documentation: https://docs.stormsoftware.com/projects/stryke\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { isBuffer } from \"./is-buffer\";\n\nconst globalObject = (obj => {\n if (typeof globalThis === \"object\") {\n return globalThis;\n }\n Object.defineProperty(obj, \"typeDetectGlobalObject\", {\n get() {\n return this;\n },\n configurable: true\n });\n\n // // biome-ignore lint/correctness/noUndeclaredVariables: <explanation>\n // const global = typeDetectGlobalObject;\n\n // // biome-ignore lint/performance/noDelete: <explanation>\n // delete obj.typeDetectGlobalObject;\n return globalThis;\n})(Object.prototype);\n\nexport function typeDetect(obj: unknown): string {\n // NOTE: isBuffer must execute before type-detect,\n // because type-detect returns 'Uint8Array'.\n if (isBuffer(obj)) {\n return \"Buffer\";\n }\n\n const typeofObj = typeof obj;\n if (typeofObj !== \"object\") {\n return typeofObj;\n }\n\n if (obj === null) {\n return \"null\";\n }\n\n if (obj === globalObject) {\n return \"global\";\n }\n\n if (\n Array.isArray(obj) &&\n (Symbol.toStringTag === undefined || !(Symbol.toStringTag in obj))\n ) {\n return \"Array\";\n }\n\n // https://html.spec.whatwg.org/multipage/browsers.html#location\n if (typeof globalThis === \"object\" && globalThis !== null) {\n if (\n typeof (globalThis as any).location === \"object\" &&\n obj === (globalThis as any).location\n ) {\n return \"Location\";\n }\n\n // https://html.spec.whatwg.org/#document\n if (\n typeof (globalThis as any).document === \"object\" &&\n obj === (globalThis as any).document\n ) {\n return \"Document\";\n }\n\n // https://html.spec.whatwg.org/multipage/webappapis.html#mimetypearray\n if (typeof (globalThis as any).navigator === \"object\") {\n if (\n typeof (globalThis as any).navigator.mimeTypes === \"object\" &&\n obj === (globalThis as any).navigator.mimeTypes\n ) {\n return \"MimeTypeArray\";\n }\n\n // https://html.spec.whatwg.org/multipage/webappapis.html#pluginarray\n if (\n typeof (globalThis as any).navigator.plugins === \"object\" &&\n obj === (globalThis as any).navigator.plugins\n ) {\n return \"PluginArray\";\n }\n }\n\n // https://html.spec.whatwg.org/multipage/webappapis.html#pluginarray\n if (\n (typeof (globalThis as any).HTMLElement === \"function\" ||\n typeof (globalThis as any).HTMLElement === \"object\") &&\n obj instanceof (globalThis as any).HTMLElement\n ) {\n if ((obj as any).tagName === \"BLOCKQUOTE\") {\n return \"HTMLQuoteElement\";\n }\n\n // https://html.spec.whatwg.org/#htmltabledatacellelement\n if ((obj as any).tagName === \"TD\") {\n return \"HTMLTableDataCellElement\";\n }\n\n // https://html.spec.whatwg.org/#htmltableheadercellelement\n if ((obj as any).tagName === \"TH\") {\n return \"HTMLTableHeaderCellElement\";\n }\n }\n }\n\n const stringTag =\n Symbol.toStringTag !== undefined && (obj as any)[Symbol.toStringTag];\n if (typeof stringTag === \"string\") {\n return stringTag;\n }\n\n const objPrototype = Object.getPrototypeOf(obj);\n if (objPrototype === RegExp.prototype) {\n return \"RegExp\";\n }\n\n if (objPrototype === Date.prototype) {\n return \"Date\";\n }\n\n // http://www.ecma-international.org/ecma-262/6.0/index.html#sec-promise.prototype-@@tostringtag\n if (typeof Promise !== \"undefined\" && objPrototype === Promise.prototype) {\n return \"Promise\";\n }\n\n if (typeof Set !== \"undefined\" && objPrototype === Set.prototype) {\n return \"Set\";\n }\n\n if (typeof Map !== \"undefined\" && objPrototype === Map.prototype) {\n return \"Map\";\n }\n\n if (typeof WeakSet !== \"undefined\" && objPrototype === WeakSet.prototype) {\n return \"WeakSet\";\n }\n\n if (typeof WeakMap !== \"undefined\" && objPrototype === WeakMap.prototype) {\n return \"WeakMap\";\n }\n\n // http://www.ecma-international.org/ecma-262/6.0/index.html#sec-dataview.prototype-@@tostringtag\n if (typeof DataView !== \"undefined\" && objPrototype === DataView.prototype) {\n return \"DataView\";\n }\n\n // http://www.ecma-international.org/ecma-262/6.0/index.html#sec-%mapiteratorprototype%-@@tostringtag\n if (\n typeof Map !== \"undefined\" &&\n objPrototype === Object.getPrototypeOf(new Map().entries())\n ) {\n return \"Map Iterator\";\n }\n\n // http://www.ecma-international.org/ecma-262/6.0/index.html#sec-%setiteratorprototype%-@@tostringtag\n if (\n typeof Set !== \"undefined\" &&\n objPrototype === Object.getPrototypeOf(new Set().entries())\n ) {\n return \"Set Iterator\";\n }\n\n // http://www.ecma-international.org/ecma-262/6.0/index.html#sec-%arrayiteratorprototype%-@@tostringtag\n if (\n typeof Array.prototype[Symbol.iterator] === \"function\" &&\n objPrototype === Object.getPrototypeOf([][Symbol.iterator]())\n ) {\n return \"Array Iterator\";\n }\n\n // http://www.ecma-international.org/ecma-262/6.0/index.html#sec-%stringiteratorprototype%-@@tostringtag\n if (\n Symbol.iterator !== undefined &&\n typeof String.prototype[Symbol.iterator] === \"function\" &&\n Object.getPrototypeOf(\"\"[Symbol.iterator]()) &&\n objPrototype === Object.getPrototypeOf(\"\"[Symbol.iterator]())\n ) {\n return \"String Iterator\";\n }\n\n if (objPrototype === null) {\n return \"Object\";\n }\n\n return Object.prototype.toString.call(obj).slice(8, -1);\n}\n"],"mappings":";;;AAoBA,MAAM,iBAAgB,QAAO;AAC3B,KAAI,OAAO,eAAe,SACxB,QAAO;AAET,QAAO,eAAe,KAAK,0BAA0B;EACnD,MAAM;AACJ,UAAO;;EAET,cAAc;EACf,CAAC;AAOF,QAAO;GACN,OAAO,UAAU"}
@@ -1,7 +0,0 @@
1
- //#region ../types/src/base.d.ts
2
- type Nullish = undefined | null;
3
- type ComputeRange<N extends number, Result extends unknown[] = []> = Result["length"] extends N ? Result : ComputeRange<N, [...Result, Result["length"]]>;
4
- type Index40 = ComputeRange<40>[number];
5
- //#endregion
6
- export { Index40, Nullish };
7
- //# sourceMappingURL=base.d.cts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"base.d.cts","names":[],"sources":["../../../../types/src/base.ts"],"mappings":";KAuIY,OAAA;AAAA,KA2OA,YAAA,oDAGR,MAAA,mBAAyB,CAAA,GACzB,MAAA,GACA,YAAA,CAAa,CAAA,MAAO,MAAA,EAAQ,MAAA;AAAA,KAEpB,OAAA,GAAU,YAAA"}
@@ -1,7 +0,0 @@
1
- //#region ../types/src/base.d.ts
2
- type Nullish = undefined | null;
3
- type ComputeRange<N extends number, Result extends unknown[] = []> = Result["length"] extends N ? Result : ComputeRange<N, [...Result, Result["length"]]>;
4
- type Index40 = ComputeRange<40>[number];
5
- //#endregion
6
- export { Index40, Nullish };
7
- //# sourceMappingURL=base.d.mts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"base.d.mts","names":[],"sources":["../../../../types/src/base.ts"],"mappings":";KAuIY,OAAA;AAAA,KA2OA,YAAA,oDAGR,MAAA,mBAAyB,CAAA,GACzB,MAAA,GACA,YAAA,CAAa,CAAA,MAAO,MAAA,EAAQ,MAAA;AAAA,KAEpB,OAAA,GAAU,YAAA"}
@@ -1,27 +0,0 @@
1
- //#region ../types/src/json.d.ts
2
- /**
3
- * Get keys of the given type as strings.
4
- *
5
- * Number keys are converted to strings.
6
- *
7
- * Use-cases:
8
- * - Get string keys from a type which may have number keys.
9
- * - Makes it possible to index using strings retrieved from template types.
10
- *
11
- * @example
12
- * ```
13
- * import type {StringKeyOf} from 'type-fest';
14
- *
15
- * type Foo = {
16
- * 1: number,
17
- * stringKey: string,
18
- * };
19
- *
20
- * type StringKeysOfFoo = StringKeyOf<Foo>;
21
- * //=> '1' | 'stringKey'
22
- * ```
23
- */
24
- type StringKeyOf<BaseType> = `${Extract<keyof BaseType, string | number>}`;
25
- //#endregion
26
- export { StringKeyOf };
27
- //# sourceMappingURL=json.d.cts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"json.d.cts","names":[],"sources":["../../../../types/src/json.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;KA2FY,WAAA,gBACP,OAAA,OAAc,QAAA"}
@@ -1,27 +0,0 @@
1
- //#region ../types/src/json.d.ts
2
- /**
3
- * Get keys of the given type as strings.
4
- *
5
- * Number keys are converted to strings.
6
- *
7
- * Use-cases:
8
- * - Get string keys from a type which may have number keys.
9
- * - Makes it possible to index using strings retrieved from template types.
10
- *
11
- * @example
12
- * ```
13
- * import type {StringKeyOf} from 'type-fest';
14
- *
15
- * type Foo = {
16
- * 1: number,
17
- * stringKey: string,
18
- * };
19
- *
20
- * type StringKeysOfFoo = StringKeyOf<Foo>;
21
- * //=> '1' | 'stringKey'
22
- * ```
23
- */
24
- type StringKeyOf<BaseType> = `${Extract<keyof BaseType, string | number>}`;
25
- //#endregion
26
- export { StringKeyOf };
27
- //# sourceMappingURL=json.d.mts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"json.d.mts","names":[],"sources":["../../../../types/src/json.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;KA2FY,WAAA,gBACP,OAAA,OAAc,QAAA"}
@@ -1,124 +0,0 @@
1
- import { Index40, Nullish } from "./base.cjs";
2
- import { StringKeyOf } from "./json.cjs";
3
- import { StringDigit } from "./string.cjs";
4
-
5
- //#region ../types/src/object.d.ts
6
- interface GetOptions {
7
- /**
8
- * Include `undefined` in the return type when accessing properties.
9
- *
10
- * Setting this to `false` is not recommended.
11
- *
12
- * @defaultValue `true`
13
- */
14
- strict?: boolean;
15
- }
16
- /**
17
- * Like the `Get` type but receives an array of strings as a path parameter.
18
- */
19
- type GetWithPath<BaseType, Keys extends readonly string[], Options extends GetOptions = {}> = Keys extends readonly [] ? BaseType : Keys extends readonly [infer Head, ...infer Tail] ? GetWithPath<PropertyOf<BaseType, Extract<Head, string>, Options>, Extract<Tail, string[]>, Options> : never;
20
- /**
21
- * Adds `undefined` to `Type` if `strict` is enabled.
22
- */
23
- type Strictify<Type, Options extends GetOptions> = Options["strict"] extends false ? Type : Type | undefined;
24
- /**
25
- * If `Options['strict']` is `true`, includes `undefined` in the returned type when accessing properties on `Record<string, any>`.
26
- *
27
- * Known limitations:
28
- * - Does not include `undefined` in the type on object types with an index signature (for example, `{a: string; [key: string]: string}`).
29
- */
30
- type StrictPropertyOf<BaseType, Key extends keyof BaseType, Options extends GetOptions> = Record<string, any> extends BaseType ? string extends keyof BaseType ? Strictify<BaseType[Key], Options> : BaseType[Key] : BaseType[Key];
31
- /**
32
- * Represents an array of strings split using a given character or character set.
33
- *
34
- * Use-case: Defining the return type of a method like `String.prototype.split`.
35
- *
36
- * @example
37
- * ```
38
- * import type {Split} from 'type-fest';
39
- *
40
- * declare function split<S extends string, D extends string>(string: S, separator: D): Split<S, D>;
41
- *
42
- * type Item = 'foo' | 'bar' | 'baz' | 'waldo';
43
- * const items = 'foo,bar,baz,waldo';
44
- * let array: Item[];
45
- *
46
- * array = split(items, ',');
47
- * ```
48
- */
49
- type Split<S extends string, Delimiter extends string> = S extends `${infer Head}${Delimiter}${infer Tail}` ? [Head, ...Split<Tail, Delimiter>] : S extends Delimiter ? [] : [S];
50
- /**
51
- * Splits a dot-prop style path into a tuple comprised of the properties in the path. Handles square-bracket notation.
52
- *
53
- * @example
54
- * ```
55
- * ToPath<'foo.bar.baz'>
56
- * //=> ['foo', 'bar', 'baz']
57
- *
58
- * ToPath<'foo[0].bar.baz'>
59
- * //=> ['foo', '0', 'bar', 'baz']
60
- * ```
61
- */
62
- type ToPath<S extends string> = Split<FixPathSquareBrackets<S>, ".">;
63
- /**
64
- * Replaces square-bracketed dot notation with dots, for example, `foo[0].bar` -\> `foo.0.bar`.
65
- */
66
- type FixPathSquareBrackets<Path extends string> = Path extends `[${infer Head}]${infer Tail}` ? Tail extends `[${string}` ? `${Head}.${FixPathSquareBrackets<Tail>}` : `${Head}${FixPathSquareBrackets<Tail>}` : Path extends `${infer Head}[${infer Middle}]${infer Tail}` ? `${Head}.${FixPathSquareBrackets<`[${Middle}]${Tail}`>}` : Path;
67
- /**
68
- * Returns true if `LongString` is made up out of `Substring` repeated 0 or more times.
69
- *
70
- * @example
71
- * ```ts
72
- * ConsistsOnlyOf<'aaa', 'a'> //=> true
73
- * ConsistsOnlyOf<'ababab', 'ab'> //=> true
74
- * ConsistsOnlyOf<'aBa', 'a'> //=> false
75
- * ConsistsOnlyOf<'', 'a'> //=> true
76
- * ```
77
- *
78
- */
79
- type ConsistsOnlyOf<LongString extends string, Substring extends string> = LongString extends "" ? true : LongString extends `${Substring}${infer Tail}` ? ConsistsOnlyOf<Tail, Substring> : false;
80
- /**
81
- * Convert a type which may have number keys to one with string keys, making it possible to index using strings retrieved from template types.
82
- *
83
- * @example
84
- *
85
- * ```ts
86
- * type WithNumbers = {foo: string; 0: boolean};
87
- * type WithStrings = WithStringKeys<WithNumbers>;
88
- *
89
- * type WithNumbersKeys = keyof WithNumbers;
90
- * //=> 'foo' | 0
91
- * type WithStringsKeys = keyof WithStrings;
92
- * //=> 'foo' | '0'
93
- * ```
94
- *
95
- */
96
- type WithStringKeys<BaseType> = { [Key in StringKeyOf<BaseType>]: UncheckedIndex<BaseType, Key> };
97
- /**
98
- Perform a `T[U]` operation if `T` supports indexing.
99
- */
100
- type UncheckedIndex<T, U extends number | string> = [T] extends [Record<number | string, any>] ? T[U] : never;
101
- /**
102
- * Get a property of an object or array. Works when indexing arrays using number-literal-strings, for example, `PropertyOf<number[], '0'> = number`, and when indexing objects with number keys.
103
- *
104
- * Note:
105
- * - Returns `unknown` if `Key` is not a property of `BaseType`, since TypeScript uses structural typing, and it cannot be guaranteed that extra properties unknown to the type system will exist at runtime.
106
- * - Returns `undefined` from nullish values, to match the behavior of most deep-key libraries like `lodash`, `dot-prop`, etc.
107
- */
108
- type PropertyOf<BaseType, Key extends string, Options extends GetOptions = {}> = BaseType extends Nullish ? undefined : Key extends keyof BaseType ? StrictPropertyOf<BaseType, Key, Options> : BaseType extends readonly [] | readonly [unknown, ...unknown[]] ? unknown : BaseType extends {
109
- [n: number]: infer Item;
110
- length: number;
111
- } ? ConsistsOnlyOf<Key, StringDigit> extends true ? Strictify<Item, Options> : unknown : Key extends keyof WithStringKeys<BaseType> ? StrictPropertyOf<WithStringKeys<BaseType>, Key, Options> : unknown;
112
- type IsTuple<T> = T extends {
113
- length: infer Length;
114
- } & readonly any[] ? Length extends Index40 ? T : never : never;
115
- type AllowedIndexes<Tuple extends readonly any[], Keys extends number = never> = Tuple extends readonly [] ? Keys : Tuple extends readonly [infer _First, ...infer Tail] ? AllowedIndexes<Tail, Keys | Tail["length"]> : Keys;
116
- type PrefixArrayAccessor<T extends any[], TDepth extends any[]> = { [K in keyof T]: `[${number}]${DeepKey<T[K], TDepth>}` }[number];
117
- type PrefixTupleAccessor<T extends any[], TIndex extends number, TDepth extends any[]> = { [K in TIndex]: `[${K}]${DeepKey<T[K], TDepth>}` | `[${K}]` }[TIndex];
118
- type PrefixObjectAccessor<T extends object, TDepth extends any[]> = { [K in keyof T]-?: K extends number | string ? `${PrefixFromDepth<K, TDepth>}${DeepKey<T[K], [TDepth]>}` | PrefixFromDepth<K, TDepth> : never }[keyof T];
119
- type PrefixFromDepth<T extends number | string, TDepth extends any[]> = TDepth["length"] extends 0 ? T : `.${T}`;
120
- type DeepKey<T, TDepth extends any[] = []> = TDepth["length"] extends 5 ? never : unknown extends T ? PrefixFromDepth<string, TDepth> : T extends IsTuple<T> & any[] ? PrefixTupleAccessor<T, AllowedIndexes<T>, TDepth> : T extends any[] ? PrefixArrayAccessor<T, [...TDepth, any]> : T extends Date ? never : T extends object ? PrefixObjectAccessor<T, TDepth> : T extends bigint | boolean | number | string ? "" : never;
121
- type DeepValue<TObject extends Record<string, unknown>, TPath extends DeepKey<TObject>> = GetWithPath<TObject, ToPath<TPath>>;
122
- //#endregion
123
- export { DeepKey, DeepValue };
124
- //# sourceMappingURL=object.d.cts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"object.d.cts","names":[],"sources":["../../../../types/src/object.ts"],"mappings":";;;;;UA8OU,UAAA;EA+EF;;;;;;;EAvEN,MAAA;AAAA;;;;KAMU,WAAA,2DAIM,UAAA,SACd,IAAA,uBACA,QAAA,GACA,IAAA,gDACE,WAAA,CACE,UAAA,CAAW,QAAA,EAAU,OAAA,CAAQ,IAAA,WAAe,OAAA,GAC5C,OAAA,CAAQ,IAAA,aACR,OAAA;;;;KAOH,SAAA,uBAEa,UAAA,IACd,OAAA,2BAAkC,IAAA,GAAO,IAAA;AA0D7C;;;;;;AAAA,KAlDK,gBAAA,6BAEe,QAAA,kBACF,UAAA,IAEhB,MAAA,sBAA4B,QAAA,wBACH,QAAA,GACnB,SAAA,CAAU,QAAA,CAAS,GAAA,GAAM,OAAA,IACzB,QAAA,CAAS,GAAA,IACX,QAAA,CAAS,GAAA;;;;;;;;AAyC6D;;;;;;;;;;;KArBhE,KAAA,+CAGR,CAAA,yBAA0B,SAAA,mBACzB,IAAA,KAAS,KAAA,CAAM,IAAA,EAAM,SAAA,KACtB,CAAA,SAAU,SAAA,SAEP,CAAA;;;;;;;;;;;;;KAcK,MAAA,qBAA2B,KAAA,CAAM,qBAAA,CAAsB,CAAA;;;;KAK9D,qBAAA,wBACH,IAAA,0CACI,IAAA,2B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AAA,KAAM,CAAA,8BAEP,eAAA,CAAgB,CAAA,EAAG,MAAA,IAAU,OAAA,CAAQ,CAAA,CAAE,CAAA,IAAK,MAAA,OAC/C,eAAA,CAAgB,CAAA,EAAG,MAAA,kBAErB,CAAA;AAAA,KAEH,eAAA,oDAGD,MAAA,uBAA6B,CAAA,OAAQ,CAAA;AAAA,KAE7B,OAAA,iCAAwC,MAAA,+CAEhC,CAAA,GACd,eAAA,SAAwB,MAAA,IACxB,CAAA,SAAU,OAAA,CAAQ,CAAA,YAChB,mBAAA,CAAoB,CAAA,EAAG,cAAA,CAAe,CAAA,GAAI,MAAA,IAC1C,CAAA,iBACE,mBAAA,CAAoB,CAAA,MAAO,MAAA,UAC3B,CAAA,SAAU,IAAA,WAER,CAAA,kBACE,oBAAA,CAAqB,CAAA,EAAG,MAAA,IACxB,CAAA;AAAA,KAaF,SAAA,iBACM,MAAA,iCACF,OAAA,CAAQ,OAAA,KACpB,WAAA,CAAY,OAAA,EAAS,MAAA,CAAO,KAAA"}
@@ -1,124 +0,0 @@
1
- import { Index40, Nullish } from "./base.mjs";
2
- import { StringKeyOf } from "./json.mjs";
3
- import { StringDigit } from "./string.mjs";
4
-
5
- //#region ../types/src/object.d.ts
6
- interface GetOptions {
7
- /**
8
- * Include `undefined` in the return type when accessing properties.
9
- *
10
- * Setting this to `false` is not recommended.
11
- *
12
- * @defaultValue `true`
13
- */
14
- strict?: boolean;
15
- }
16
- /**
17
- * Like the `Get` type but receives an array of strings as a path parameter.
18
- */
19
- type GetWithPath<BaseType, Keys extends readonly string[], Options extends GetOptions = {}> = Keys extends readonly [] ? BaseType : Keys extends readonly [infer Head, ...infer Tail] ? GetWithPath<PropertyOf<BaseType, Extract<Head, string>, Options>, Extract<Tail, string[]>, Options> : never;
20
- /**
21
- * Adds `undefined` to `Type` if `strict` is enabled.
22
- */
23
- type Strictify<Type, Options extends GetOptions> = Options["strict"] extends false ? Type : Type | undefined;
24
- /**
25
- * If `Options['strict']` is `true`, includes `undefined` in the returned type when accessing properties on `Record<string, any>`.
26
- *
27
- * Known limitations:
28
- * - Does not include `undefined` in the type on object types with an index signature (for example, `{a: string; [key: string]: string}`).
29
- */
30
- type StrictPropertyOf<BaseType, Key extends keyof BaseType, Options extends GetOptions> = Record<string, any> extends BaseType ? string extends keyof BaseType ? Strictify<BaseType[Key], Options> : BaseType[Key] : BaseType[Key];
31
- /**
32
- * Represents an array of strings split using a given character or character set.
33
- *
34
- * Use-case: Defining the return type of a method like `String.prototype.split`.
35
- *
36
- * @example
37
- * ```
38
- * import type {Split} from 'type-fest';
39
- *
40
- * declare function split<S extends string, D extends string>(string: S, separator: D): Split<S, D>;
41
- *
42
- * type Item = 'foo' | 'bar' | 'baz' | 'waldo';
43
- * const items = 'foo,bar,baz,waldo';
44
- * let array: Item[];
45
- *
46
- * array = split(items, ',');
47
- * ```
48
- */
49
- type Split<S extends string, Delimiter extends string> = S extends `${infer Head}${Delimiter}${infer Tail}` ? [Head, ...Split<Tail, Delimiter>] : S extends Delimiter ? [] : [S];
50
- /**
51
- * Splits a dot-prop style path into a tuple comprised of the properties in the path. Handles square-bracket notation.
52
- *
53
- * @example
54
- * ```
55
- * ToPath<'foo.bar.baz'>
56
- * //=> ['foo', 'bar', 'baz']
57
- *
58
- * ToPath<'foo[0].bar.baz'>
59
- * //=> ['foo', '0', 'bar', 'baz']
60
- * ```
61
- */
62
- type ToPath<S extends string> = Split<FixPathSquareBrackets<S>, ".">;
63
- /**
64
- * Replaces square-bracketed dot notation with dots, for example, `foo[0].bar` -\> `foo.0.bar`.
65
- */
66
- type FixPathSquareBrackets<Path extends string> = Path extends `[${infer Head}]${infer Tail}` ? Tail extends `[${string}` ? `${Head}.${FixPathSquareBrackets<Tail>}` : `${Head}${FixPathSquareBrackets<Tail>}` : Path extends `${infer Head}[${infer Middle}]${infer Tail}` ? `${Head}.${FixPathSquareBrackets<`[${Middle}]${Tail}`>}` : Path;
67
- /**
68
- * Returns true if `LongString` is made up out of `Substring` repeated 0 or more times.
69
- *
70
- * @example
71
- * ```ts
72
- * ConsistsOnlyOf<'aaa', 'a'> //=> true
73
- * ConsistsOnlyOf<'ababab', 'ab'> //=> true
74
- * ConsistsOnlyOf<'aBa', 'a'> //=> false
75
- * ConsistsOnlyOf<'', 'a'> //=> true
76
- * ```
77
- *
78
- */
79
- type ConsistsOnlyOf<LongString extends string, Substring extends string> = LongString extends "" ? true : LongString extends `${Substring}${infer Tail}` ? ConsistsOnlyOf<Tail, Substring> : false;
80
- /**
81
- * Convert a type which may have number keys to one with string keys, making it possible to index using strings retrieved from template types.
82
- *
83
- * @example
84
- *
85
- * ```ts
86
- * type WithNumbers = {foo: string; 0: boolean};
87
- * type WithStrings = WithStringKeys<WithNumbers>;
88
- *
89
- * type WithNumbersKeys = keyof WithNumbers;
90
- * //=> 'foo' | 0
91
- * type WithStringsKeys = keyof WithStrings;
92
- * //=> 'foo' | '0'
93
- * ```
94
- *
95
- */
96
- type WithStringKeys<BaseType> = { [Key in StringKeyOf<BaseType>]: UncheckedIndex<BaseType, Key> };
97
- /**
98
- Perform a `T[U]` operation if `T` supports indexing.
99
- */
100
- type UncheckedIndex<T, U extends number | string> = [T] extends [Record<number | string, any>] ? T[U] : never;
101
- /**
102
- * Get a property of an object or array. Works when indexing arrays using number-literal-strings, for example, `PropertyOf<number[], '0'> = number`, and when indexing objects with number keys.
103
- *
104
- * Note:
105
- * - Returns `unknown` if `Key` is not a property of `BaseType`, since TypeScript uses structural typing, and it cannot be guaranteed that extra properties unknown to the type system will exist at runtime.
106
- * - Returns `undefined` from nullish values, to match the behavior of most deep-key libraries like `lodash`, `dot-prop`, etc.
107
- */
108
- type PropertyOf<BaseType, Key extends string, Options extends GetOptions = {}> = BaseType extends Nullish ? undefined : Key extends keyof BaseType ? StrictPropertyOf<BaseType, Key, Options> : BaseType extends readonly [] | readonly [unknown, ...unknown[]] ? unknown : BaseType extends {
109
- [n: number]: infer Item;
110
- length: number;
111
- } ? ConsistsOnlyOf<Key, StringDigit> extends true ? Strictify<Item, Options> : unknown : Key extends keyof WithStringKeys<BaseType> ? StrictPropertyOf<WithStringKeys<BaseType>, Key, Options> : unknown;
112
- type IsTuple<T> = T extends {
113
- length: infer Length;
114
- } & readonly any[] ? Length extends Index40 ? T : never : never;
115
- type AllowedIndexes<Tuple extends readonly any[], Keys extends number = never> = Tuple extends readonly [] ? Keys : Tuple extends readonly [infer _First, ...infer Tail] ? AllowedIndexes<Tail, Keys | Tail["length"]> : Keys;
116
- type PrefixArrayAccessor<T extends any[], TDepth extends any[]> = { [K in keyof T]: `[${number}]${DeepKey<T[K], TDepth>}` }[number];
117
- type PrefixTupleAccessor<T extends any[], TIndex extends number, TDepth extends any[]> = { [K in TIndex]: `[${K}]${DeepKey<T[K], TDepth>}` | `[${K}]` }[TIndex];
118
- type PrefixObjectAccessor<T extends object, TDepth extends any[]> = { [K in keyof T]-?: K extends number | string ? `${PrefixFromDepth<K, TDepth>}${DeepKey<T[K], [TDepth]>}` | PrefixFromDepth<K, TDepth> : never }[keyof T];
119
- type PrefixFromDepth<T extends number | string, TDepth extends any[]> = TDepth["length"] extends 0 ? T : `.${T}`;
120
- type DeepKey<T, TDepth extends any[] = []> = TDepth["length"] extends 5 ? never : unknown extends T ? PrefixFromDepth<string, TDepth> : T extends IsTuple<T> & any[] ? PrefixTupleAccessor<T, AllowedIndexes<T>, TDepth> : T extends any[] ? PrefixArrayAccessor<T, [...TDepth, any]> : T extends Date ? never : T extends object ? PrefixObjectAccessor<T, TDepth> : T extends bigint | boolean | number | string ? "" : never;
121
- type DeepValue<TObject extends Record<string, unknown>, TPath extends DeepKey<TObject>> = GetWithPath<TObject, ToPath<TPath>>;
122
- //#endregion
123
- export { DeepKey, DeepValue };
124
- //# sourceMappingURL=object.d.mts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"object.d.mts","names":[],"sources":["../../../../types/src/object.ts"],"mappings":";;;;;UA8OU,UAAA;EA+EF;;;;;;;EAvEN,MAAA;AAAA;;;;KAMU,W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,iBACM,MAAA,iCACF,OAAA,CAAQ,OAAA,KACpB,WAAA,CAAY,OAAA,EAAS,MAAA,CAAO,KAAA"}
@@ -1,5 +0,0 @@
1
- //#region ../types/src/string.d.ts
2
- type StringDigit = "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9";
3
- //#endregion
4
- export { StringDigit };
5
- //# sourceMappingURL=string.d.cts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"string.d.cts","names":[],"sources":["../../../../types/src/string.ts"],"mappings":";KAiJY,WAAA"}
@@ -1,5 +0,0 @@
1
- //#region ../types/src/string.d.ts
2
- type StringDigit = "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9";
3
- //#endregion
4
- export { StringDigit };
5
- //# sourceMappingURL=string.d.mts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"string.d.mts","names":[],"sources":["../../../../types/src/string.ts"],"mappings":";KAiJY,WAAA"}