@trackunit/irisx-proxy 1.6.6 → 1.6.12
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.
- package/index.cjs.js +1 -1
- package/index.esm.js +1 -1
- package/package.json +6 -6
- package/src/utils.d.ts +1 -1
package/index.cjs.js
CHANGED
|
@@ -139,7 +139,7 @@ const irisAppProxySchema = zod.z.object({
|
|
|
139
139
|
*
|
|
140
140
|
* @template TResponse - The type inferred from the response schema.
|
|
141
141
|
* @param {string} responseBody - The base64-encoded response body from the API.
|
|
142
|
-
* @param {
|
|
142
|
+
* @param {ZodType<TResponse>} responseSchema - The Zod schema used to validate and parse the response data.
|
|
143
143
|
* @returns {TResponse| null} The parsed and validated response data of type `T`, or `null` if validation fails.
|
|
144
144
|
*/
|
|
145
145
|
const validateAndParseResponse = (responseBody, responseSchema) => {
|
package/index.esm.js
CHANGED
|
@@ -137,7 +137,7 @@ const irisAppProxySchema = z.object({
|
|
|
137
137
|
*
|
|
138
138
|
* @template TResponse - The type inferred from the response schema.
|
|
139
139
|
* @param {string} responseBody - The base64-encoded response body from the API.
|
|
140
|
-
* @param {
|
|
140
|
+
* @param {ZodType<TResponse>} responseSchema - The Zod schema used to validate and parse the response data.
|
|
141
141
|
* @returns {TResponse| null} The parsed and validated response data of type `T`, or `null` if validation fails.
|
|
142
142
|
*/
|
|
143
143
|
const validateAndParseResponse = (responseBody, responseSchema) => {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@trackunit/irisx-proxy",
|
|
3
|
-
"version": "1.6.
|
|
3
|
+
"version": "1.6.12",
|
|
4
4
|
"repository": "https://github.com/Trackunit/manager",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE.txt",
|
|
6
6
|
"engines": {
|
|
@@ -14,11 +14,11 @@
|
|
|
14
14
|
"@graphql-typed-document-node/core": "^3.2.0",
|
|
15
15
|
"zod": "^3.23.8",
|
|
16
16
|
"jest-fetch-mock": "^3.0.3",
|
|
17
|
-
"@trackunit/iris-app-build-utilities": "1.6.
|
|
18
|
-
"@trackunit/iris-app-api": "1.6.
|
|
19
|
-
"@trackunit/react-core-contexts-test": "1.6.
|
|
20
|
-
"@trackunit/shared-utils": "1.8.
|
|
21
|
-
"@trackunit/react-test-setup": "1.3.
|
|
17
|
+
"@trackunit/iris-app-build-utilities": "1.6.11",
|
|
18
|
+
"@trackunit/iris-app-api": "1.6.11",
|
|
19
|
+
"@trackunit/react-core-contexts-test": "1.6.12",
|
|
20
|
+
"@trackunit/shared-utils": "1.8.12",
|
|
21
|
+
"@trackunit/react-test-setup": "1.3.12"
|
|
22
22
|
},
|
|
23
23
|
"module": "./index.esm.js",
|
|
24
24
|
"main": "./index.cjs.js",
|
package/src/utils.d.ts
CHANGED
|
@@ -5,7 +5,7 @@ import { ProxyError } from "./useIrisAppProxy";
|
|
|
5
5
|
*
|
|
6
6
|
* @template TResponse - The type inferred from the response schema.
|
|
7
7
|
* @param {string} responseBody - The base64-encoded response body from the API.
|
|
8
|
-
* @param {
|
|
8
|
+
* @param {ZodType<TResponse>} responseSchema - The Zod schema used to validate and parse the response data.
|
|
9
9
|
* @returns {TResponse| null} The parsed and validated response data of type `T`, or `null` if validation fails.
|
|
10
10
|
*/
|
|
11
11
|
export declare const validateAndParseResponse: <TResponse>(responseBody: string, responseSchema: z.ZodType<TResponse>) => {
|