@trpc/react-query 11.18.1-canary.6 → 11.19.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.
- package/dist/getQueryKey-4D2iXfB-.cjs +193 -0
- package/dist/getQueryKey-B1x5Ak4F.mjs +132 -0
- package/dist/getQueryKey-B1x5Ak4F.mjs.map +1 -0
- package/dist/{getQueryKey.d-CruH3ncI.d.mts → getQueryKey-Bw7DtJ4y.d.cts} +21 -46
- package/dist/getQueryKey-Bw7DtJ4y.d.cts.map +1 -0
- package/dist/{getQueryKey.d-C_PnqPni.d.cts → getQueryKey-Cgg9jecL.d.mts} +21 -46
- package/dist/getQueryKey-Cgg9jecL.d.mts.map +1 -0
- package/dist/index.cjs +16 -17
- package/dist/index.d.cts +3 -12
- package/dist/index.d.cts.map +1 -1
- package/dist/index.d.mts +3 -12
- package/dist/index.d.mts.map +1 -1
- package/dist/index.mjs +5 -10
- package/dist/index.mjs.map +1 -1
- package/dist/rsc.cjs +49 -17
- package/dist/rsc.d.cts +3 -5
- package/dist/rsc.d.cts.map +1 -1
- package/dist/rsc.d.mts +3 -5
- package/dist/rsc.d.mts.map +1 -1
- package/dist/rsc.mjs +43 -11
- package/dist/rsc.mjs.map +1 -1
- package/dist/server/index.cjs +30 -35
- package/dist/server/index.d.cts +3 -5
- package/dist/server/index.d.cts.map +1 -1
- package/dist/server/index.d.mts +3 -5
- package/dist/server/index.d.mts.map +1 -1
- package/dist/server/index.mjs +20 -25
- package/dist/server/index.mjs.map +1 -1
- package/dist/shared/index.cjs +3 -4
- package/dist/shared/index.d.cts +2 -2
- package/dist/shared/index.d.mts +2 -2
- package/dist/shared/index.mjs +2 -4
- package/dist/{shared-Dt4RsQVp.cjs → shared-BhNi4Oqs.cjs} +210 -237
- package/dist/{shared-JtnEvJvB.mjs → shared-DhkLzxq7.mjs} +131 -160
- package/dist/shared-DhkLzxq7.mjs.map +1 -0
- package/package.json +11 -11
- package/src/createTRPCReact.tsx +1 -2
- package/src/index.ts +1 -0
- package/src/internals/context.tsx +10 -4
- package/src/internals/getQueryKey.ts +1 -3
- package/src/internals/useQueries.ts +9 -3
- package/src/shared/hooks/createHooksInternal.tsx +0 -1
- package/src/shared/hooks/types.ts +37 -20
- package/src/shared/types.ts +31 -12
- package/src/utils/createUtilityFunctions.ts +2 -2
- package/dist/getQueryKey-BY58RNzP.mjs +0 -196
- package/dist/getQueryKey-BY58RNzP.mjs.map +0 -1
- package/dist/getQueryKey-PyKLS56S.cjs +0 -242
- package/dist/getQueryKey.d-C_PnqPni.d.cts.map +0 -1
- package/dist/getQueryKey.d-CruH3ncI.d.mts.map +0 -1
- package/dist/shared-JtnEvJvB.mjs.map +0 -1
|
@@ -0,0 +1,193 @@
|
|
|
1
|
+
//#region \0rolldown/runtime.js
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __copyProps = (to, from, except, desc) => {
|
|
9
|
+
if (from && typeof from === "object" || typeof from === "function") for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
|
|
10
|
+
key = keys[i];
|
|
11
|
+
if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
12
|
+
get: ((k) => from[k]).bind(null, key),
|
|
13
|
+
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
14
|
+
});
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule || !__hasOwnProp.call(mod, "default") ? __defProp(target, "default", {
|
|
19
|
+
value: mod,
|
|
20
|
+
enumerable: true
|
|
21
|
+
}) : target, mod));
|
|
22
|
+
//#endregion
|
|
23
|
+
let _tanstack_react_query = require("@tanstack/react-query");
|
|
24
|
+
let _trpc_server_unstable_core_do_not_import = require("@trpc/server/unstable-core-do-not-import");
|
|
25
|
+
//#region \0@oxc-project+runtime@0.149.0/helpers/esm/objectWithoutPropertiesLoose.js
|
|
26
|
+
function _objectWithoutPropertiesLoose(r, e) {
|
|
27
|
+
if (null == r) return {};
|
|
28
|
+
var t = {};
|
|
29
|
+
for (var n in r) if ({}.hasOwnProperty.call(r, n)) {
|
|
30
|
+
if (e.includes(n)) continue;
|
|
31
|
+
t[n] = r[n];
|
|
32
|
+
}
|
|
33
|
+
return t;
|
|
34
|
+
}
|
|
35
|
+
//#endregion
|
|
36
|
+
//#region \0@oxc-project+runtime@0.149.0/helpers/esm/objectWithoutProperties.js
|
|
37
|
+
function _objectWithoutProperties(e, t) {
|
|
38
|
+
if (null == e) return {};
|
|
39
|
+
var o, r, i = _objectWithoutPropertiesLoose(e, t);
|
|
40
|
+
if (Object.getOwnPropertySymbols) {
|
|
41
|
+
var s = Object.getOwnPropertySymbols(e);
|
|
42
|
+
for (r = 0; r < s.length; r++) o = s[r], t.includes(o) || {}.propertyIsEnumerable.call(e, o) && (i[o] = e[o]);
|
|
43
|
+
}
|
|
44
|
+
return i;
|
|
45
|
+
}
|
|
46
|
+
//#endregion
|
|
47
|
+
//#region \0@oxc-project+runtime@0.149.0/helpers/esm/typeof.js
|
|
48
|
+
function _typeof(o) {
|
|
49
|
+
"@babel/helpers - typeof";
|
|
50
|
+
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(o) {
|
|
51
|
+
return typeof o;
|
|
52
|
+
} : function(o) {
|
|
53
|
+
return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;
|
|
54
|
+
}, _typeof(o);
|
|
55
|
+
}
|
|
56
|
+
//#endregion
|
|
57
|
+
//#region \0@oxc-project+runtime@0.149.0/helpers/esm/toPrimitive.js
|
|
58
|
+
function toPrimitive(t, r) {
|
|
59
|
+
if ("object" != _typeof(t) || !t) return t;
|
|
60
|
+
var e = t[Symbol.toPrimitive];
|
|
61
|
+
if (void 0 !== e) {
|
|
62
|
+
var i = e.call(t, r || "default");
|
|
63
|
+
if ("object" != _typeof(i)) return i;
|
|
64
|
+
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
65
|
+
}
|
|
66
|
+
return ("string" === r ? String : Number)(t);
|
|
67
|
+
}
|
|
68
|
+
//#endregion
|
|
69
|
+
//#region \0@oxc-project+runtime@0.149.0/helpers/esm/toPropertyKey.js
|
|
70
|
+
function toPropertyKey(t) {
|
|
71
|
+
var i = toPrimitive(t, "string");
|
|
72
|
+
return "symbol" == _typeof(i) ? i : i + "";
|
|
73
|
+
}
|
|
74
|
+
//#endregion
|
|
75
|
+
//#region \0@oxc-project+runtime@0.149.0/helpers/esm/defineProperty.js
|
|
76
|
+
function _defineProperty(e, r, t) {
|
|
77
|
+
return (r = toPropertyKey(r)) in e ? Object.defineProperty(e, r, {
|
|
78
|
+
value: t,
|
|
79
|
+
enumerable: !0,
|
|
80
|
+
configurable: !0,
|
|
81
|
+
writable: !0
|
|
82
|
+
}) : e[r] = t, e;
|
|
83
|
+
}
|
|
84
|
+
//#endregion
|
|
85
|
+
//#region \0@oxc-project+runtime@0.149.0/helpers/esm/objectSpread2.js
|
|
86
|
+
function ownKeys(e, r) {
|
|
87
|
+
var t = Object.keys(e);
|
|
88
|
+
if (Object.getOwnPropertySymbols) {
|
|
89
|
+
var o = Object.getOwnPropertySymbols(e);
|
|
90
|
+
r && (o = o.filter(function(r) {
|
|
91
|
+
return Object.getOwnPropertyDescriptor(e, r).enumerable;
|
|
92
|
+
})), t.push.apply(t, o);
|
|
93
|
+
}
|
|
94
|
+
return t;
|
|
95
|
+
}
|
|
96
|
+
function _objectSpread2(e) {
|
|
97
|
+
for (var r = 1; r < arguments.length; r++) {
|
|
98
|
+
var t = null != arguments[r] ? arguments[r] : {};
|
|
99
|
+
r % 2 ? ownKeys(Object(t), !0).forEach(function(r) {
|
|
100
|
+
_defineProperty(e, r, t[r]);
|
|
101
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function(r) {
|
|
102
|
+
Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));
|
|
103
|
+
});
|
|
104
|
+
}
|
|
105
|
+
return e;
|
|
106
|
+
}
|
|
107
|
+
//#endregion
|
|
108
|
+
//#region src/internals/getQueryKey.ts
|
|
109
|
+
const _excluded = ["cursor", "direction"];
|
|
110
|
+
/**
|
|
111
|
+
* To allow easy interactions with groups of related queries, such as
|
|
112
|
+
* invalidating all queries of a router, we use an array as the path when
|
|
113
|
+
* storing in tanstack query.
|
|
114
|
+
**/
|
|
115
|
+
function getQueryKeyInternal(path, input, type) {
|
|
116
|
+
const splitPath = path.flatMap((part) => part.split("."));
|
|
117
|
+
if (!input && (!type || type === "any")) return splitPath.length ? [splitPath] : [];
|
|
118
|
+
if (type === "infinite" && (0, _trpc_server_unstable_core_do_not_import.isObject)(input) && ("direction" in input || "cursor" in input)) {
|
|
119
|
+
const { cursor: _, direction: __ } = input;
|
|
120
|
+
return [splitPath, {
|
|
121
|
+
input: _objectWithoutProperties(input, _excluded),
|
|
122
|
+
type: "infinite"
|
|
123
|
+
}];
|
|
124
|
+
}
|
|
125
|
+
return [splitPath, _objectSpread2(_objectSpread2({}, typeof input !== "undefined" && input !== _tanstack_react_query.skipToken && { input }), type && type !== "any" && { type })];
|
|
126
|
+
}
|
|
127
|
+
function getMutationKeyInternal(path) {
|
|
128
|
+
return getQueryKeyInternal(path, void 0, "any");
|
|
129
|
+
}
|
|
130
|
+
/**
|
|
131
|
+
* Method to extract the query key for a procedure
|
|
132
|
+
* @param procedureOrRouter - procedure or AnyRouter
|
|
133
|
+
* @param input - input to procedureOrRouter
|
|
134
|
+
* @param type - defaults to `any`
|
|
135
|
+
* @see https://trpc.io/docs/v11/getQueryKey
|
|
136
|
+
*/
|
|
137
|
+
function getQueryKey(procedureOrRouter, ..._params) {
|
|
138
|
+
const [input, type] = _params;
|
|
139
|
+
const path = procedureOrRouter._def().path;
|
|
140
|
+
return getQueryKeyInternal(path, input, type !== null && type !== void 0 ? type : "any");
|
|
141
|
+
}
|
|
142
|
+
/**
|
|
143
|
+
* Method to extract the mutation key for a procedure
|
|
144
|
+
* @param procedure - procedure
|
|
145
|
+
* @see https://trpc.io/docs/v11/getQueryKey#mutations
|
|
146
|
+
*/
|
|
147
|
+
function getMutationKey(procedure) {
|
|
148
|
+
const path = procedure._def().path;
|
|
149
|
+
return getMutationKeyInternal(path);
|
|
150
|
+
}
|
|
151
|
+
//#endregion
|
|
152
|
+
Object.defineProperty(exports, "__toESM", {
|
|
153
|
+
enumerable: true,
|
|
154
|
+
get: function() {
|
|
155
|
+
return __toESM;
|
|
156
|
+
}
|
|
157
|
+
});
|
|
158
|
+
Object.defineProperty(exports, "_objectSpread2", {
|
|
159
|
+
enumerable: true,
|
|
160
|
+
get: function() {
|
|
161
|
+
return _objectSpread2;
|
|
162
|
+
}
|
|
163
|
+
});
|
|
164
|
+
Object.defineProperty(exports, "_objectWithoutProperties", {
|
|
165
|
+
enumerable: true,
|
|
166
|
+
get: function() {
|
|
167
|
+
return _objectWithoutProperties;
|
|
168
|
+
}
|
|
169
|
+
});
|
|
170
|
+
Object.defineProperty(exports, "getMutationKey", {
|
|
171
|
+
enumerable: true,
|
|
172
|
+
get: function() {
|
|
173
|
+
return getMutationKey;
|
|
174
|
+
}
|
|
175
|
+
});
|
|
176
|
+
Object.defineProperty(exports, "getMutationKeyInternal", {
|
|
177
|
+
enumerable: true,
|
|
178
|
+
get: function() {
|
|
179
|
+
return getMutationKeyInternal;
|
|
180
|
+
}
|
|
181
|
+
});
|
|
182
|
+
Object.defineProperty(exports, "getQueryKey", {
|
|
183
|
+
enumerable: true,
|
|
184
|
+
get: function() {
|
|
185
|
+
return getQueryKey;
|
|
186
|
+
}
|
|
187
|
+
});
|
|
188
|
+
Object.defineProperty(exports, "getQueryKeyInternal", {
|
|
189
|
+
enumerable: true,
|
|
190
|
+
get: function() {
|
|
191
|
+
return getQueryKeyInternal;
|
|
192
|
+
}
|
|
193
|
+
});
|
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
import { skipToken } from "@tanstack/react-query";
|
|
2
|
+
import { isObject } from "@trpc/server/unstable-core-do-not-import";
|
|
3
|
+
//#region \0@oxc-project+runtime@0.149.0/helpers/esm/objectWithoutPropertiesLoose.js
|
|
4
|
+
function _objectWithoutPropertiesLoose(r, e) {
|
|
5
|
+
if (null == r) return {};
|
|
6
|
+
var t = {};
|
|
7
|
+
for (var n in r) if ({}.hasOwnProperty.call(r, n)) {
|
|
8
|
+
if (e.includes(n)) continue;
|
|
9
|
+
t[n] = r[n];
|
|
10
|
+
}
|
|
11
|
+
return t;
|
|
12
|
+
}
|
|
13
|
+
//#endregion
|
|
14
|
+
//#region \0@oxc-project+runtime@0.149.0/helpers/esm/objectWithoutProperties.js
|
|
15
|
+
function _objectWithoutProperties(e, t) {
|
|
16
|
+
if (null == e) return {};
|
|
17
|
+
var o, r, i = _objectWithoutPropertiesLoose(e, t);
|
|
18
|
+
if (Object.getOwnPropertySymbols) {
|
|
19
|
+
var s = Object.getOwnPropertySymbols(e);
|
|
20
|
+
for (r = 0; r < s.length; r++) o = s[r], t.includes(o) || {}.propertyIsEnumerable.call(e, o) && (i[o] = e[o]);
|
|
21
|
+
}
|
|
22
|
+
return i;
|
|
23
|
+
}
|
|
24
|
+
//#endregion
|
|
25
|
+
//#region \0@oxc-project+runtime@0.149.0/helpers/esm/typeof.js
|
|
26
|
+
function _typeof(o) {
|
|
27
|
+
"@babel/helpers - typeof";
|
|
28
|
+
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(o) {
|
|
29
|
+
return typeof o;
|
|
30
|
+
} : function(o) {
|
|
31
|
+
return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;
|
|
32
|
+
}, _typeof(o);
|
|
33
|
+
}
|
|
34
|
+
//#endregion
|
|
35
|
+
//#region \0@oxc-project+runtime@0.149.0/helpers/esm/toPrimitive.js
|
|
36
|
+
function toPrimitive(t, r) {
|
|
37
|
+
if ("object" != _typeof(t) || !t) return t;
|
|
38
|
+
var e = t[Symbol.toPrimitive];
|
|
39
|
+
if (void 0 !== e) {
|
|
40
|
+
var i = e.call(t, r || "default");
|
|
41
|
+
if ("object" != _typeof(i)) return i;
|
|
42
|
+
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
43
|
+
}
|
|
44
|
+
return ("string" === r ? String : Number)(t);
|
|
45
|
+
}
|
|
46
|
+
//#endregion
|
|
47
|
+
//#region \0@oxc-project+runtime@0.149.0/helpers/esm/toPropertyKey.js
|
|
48
|
+
function toPropertyKey(t) {
|
|
49
|
+
var i = toPrimitive(t, "string");
|
|
50
|
+
return "symbol" == _typeof(i) ? i : i + "";
|
|
51
|
+
}
|
|
52
|
+
//#endregion
|
|
53
|
+
//#region \0@oxc-project+runtime@0.149.0/helpers/esm/defineProperty.js
|
|
54
|
+
function _defineProperty(e, r, t) {
|
|
55
|
+
return (r = toPropertyKey(r)) in e ? Object.defineProperty(e, r, {
|
|
56
|
+
value: t,
|
|
57
|
+
enumerable: !0,
|
|
58
|
+
configurable: !0,
|
|
59
|
+
writable: !0
|
|
60
|
+
}) : e[r] = t, e;
|
|
61
|
+
}
|
|
62
|
+
//#endregion
|
|
63
|
+
//#region \0@oxc-project+runtime@0.149.0/helpers/esm/objectSpread2.js
|
|
64
|
+
function ownKeys(e, r) {
|
|
65
|
+
var t = Object.keys(e);
|
|
66
|
+
if (Object.getOwnPropertySymbols) {
|
|
67
|
+
var o = Object.getOwnPropertySymbols(e);
|
|
68
|
+
r && (o = o.filter(function(r) {
|
|
69
|
+
return Object.getOwnPropertyDescriptor(e, r).enumerable;
|
|
70
|
+
})), t.push.apply(t, o);
|
|
71
|
+
}
|
|
72
|
+
return t;
|
|
73
|
+
}
|
|
74
|
+
function _objectSpread2(e) {
|
|
75
|
+
for (var r = 1; r < arguments.length; r++) {
|
|
76
|
+
var t = null != arguments[r] ? arguments[r] : {};
|
|
77
|
+
r % 2 ? ownKeys(Object(t), !0).forEach(function(r) {
|
|
78
|
+
_defineProperty(e, r, t[r]);
|
|
79
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function(r) {
|
|
80
|
+
Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));
|
|
81
|
+
});
|
|
82
|
+
}
|
|
83
|
+
return e;
|
|
84
|
+
}
|
|
85
|
+
//#endregion
|
|
86
|
+
//#region src/internals/getQueryKey.ts
|
|
87
|
+
const _excluded = ["cursor", "direction"];
|
|
88
|
+
/**
|
|
89
|
+
* To allow easy interactions with groups of related queries, such as
|
|
90
|
+
* invalidating all queries of a router, we use an array as the path when
|
|
91
|
+
* storing in tanstack query.
|
|
92
|
+
**/
|
|
93
|
+
function getQueryKeyInternal(path, input, type) {
|
|
94
|
+
const splitPath = path.flatMap((part) => part.split("."));
|
|
95
|
+
if (!input && (!type || type === "any")) return splitPath.length ? [splitPath] : [];
|
|
96
|
+
if (type === "infinite" && isObject(input) && ("direction" in input || "cursor" in input)) {
|
|
97
|
+
const { cursor: _, direction: __ } = input;
|
|
98
|
+
return [splitPath, {
|
|
99
|
+
input: _objectWithoutProperties(input, _excluded),
|
|
100
|
+
type: "infinite"
|
|
101
|
+
}];
|
|
102
|
+
}
|
|
103
|
+
return [splitPath, _objectSpread2(_objectSpread2({}, typeof input !== "undefined" && input !== skipToken && { input }), type && type !== "any" && { type })];
|
|
104
|
+
}
|
|
105
|
+
function getMutationKeyInternal(path) {
|
|
106
|
+
return getQueryKeyInternal(path, void 0, "any");
|
|
107
|
+
}
|
|
108
|
+
/**
|
|
109
|
+
* Method to extract the query key for a procedure
|
|
110
|
+
* @param procedureOrRouter - procedure or AnyRouter
|
|
111
|
+
* @param input - input to procedureOrRouter
|
|
112
|
+
* @param type - defaults to `any`
|
|
113
|
+
* @see https://trpc.io/docs/v11/getQueryKey
|
|
114
|
+
*/
|
|
115
|
+
function getQueryKey(procedureOrRouter, ..._params) {
|
|
116
|
+
const [input, type] = _params;
|
|
117
|
+
const path = procedureOrRouter._def().path;
|
|
118
|
+
return getQueryKeyInternal(path, input, type !== null && type !== void 0 ? type : "any");
|
|
119
|
+
}
|
|
120
|
+
/**
|
|
121
|
+
* Method to extract the mutation key for a procedure
|
|
122
|
+
* @param procedure - procedure
|
|
123
|
+
* @see https://trpc.io/docs/v11/getQueryKey#mutations
|
|
124
|
+
*/
|
|
125
|
+
function getMutationKey(procedure) {
|
|
126
|
+
const path = procedure._def().path;
|
|
127
|
+
return getMutationKeyInternal(path);
|
|
128
|
+
}
|
|
129
|
+
//#endregion
|
|
130
|
+
export { _objectSpread2 as a, getQueryKeyInternal as i, getMutationKeyInternal as n, _objectWithoutProperties as o, getQueryKey as r, getMutationKey as t };
|
|
131
|
+
|
|
132
|
+
//# sourceMappingURL=getQueryKey-B1x5Ak4F.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"getQueryKey-B1x5Ak4F.mjs","names":[],"sources":["../src/internals/getQueryKey.ts"],"sourcesContent":["import { skipToken } from '@tanstack/react-query';\nimport {\n isObject,\n type DeepPartial,\n} from '@trpc/server/unstable-core-do-not-import';\nimport type { DecoratedMutation, DecoratedQuery } from '../createTRPCReact';\nimport type { DecorateRouterRecord } from '../shared';\n\nexport type QueryType = 'any' | 'infinite' | 'query';\n\nexport type TRPCQueryKey = [\n readonly string[],\n { input?: unknown; type?: Exclude<QueryType, 'any'> }?,\n];\n\nexport type TRPCMutationKey = [readonly string[]]; // = [TRPCQueryKey[0]]\n\ntype ProcedureOrRouter =\n DecoratedMutation<any> | DecoratedQuery<any> | DecorateRouterRecord<any, any>;\n\n/**\n * To allow easy interactions with groups of related queries, such as\n * invalidating all queries of a router, we use an array as the path when\n * storing in tanstack query.\n **/\nexport function getQueryKeyInternal(\n path: readonly string[],\n input: unknown,\n type: QueryType,\n): TRPCQueryKey {\n // Construct a query key that is easy to destructure and flexible for\n // partial selecting etc.\n // https://github.com/trpc/trpc/issues/3128\n\n // some parts of the path may be dot-separated, split them up\n const splitPath = path.flatMap((part) => part.split('.'));\n\n if (!input && (!type || type === 'any')) {\n // this matches also all mutations (see `getMutationKeyInternal`)\n\n // for `utils.invalidate()` to match all queries (including vanilla react-query)\n // we don't want nested array if path is empty, i.e. `[]` instead of `[[]]`\n return splitPath.length ? [splitPath] : ([] as unknown as TRPCQueryKey);\n }\n\n if (\n type === 'infinite' &&\n isObject(input) &&\n ('direction' in input || 'cursor' in input)\n ) {\n const {\n cursor: _,\n direction: __,\n ...inputWithoutCursorAndDirection\n } = input;\n return [\n splitPath,\n {\n input: inputWithoutCursorAndDirection,\n type: 'infinite',\n },\n ];\n }\n return [\n splitPath,\n {\n ...(typeof input !== 'undefined' &&\n input !== skipToken && { input: input }),\n ...(type && type !== 'any' && { type: type }),\n },\n ];\n}\n\nexport function getMutationKeyInternal(path: readonly string[]) {\n return getQueryKeyInternal(path, undefined, 'any') as TRPCMutationKey;\n}\n\ntype GetInfiniteQueryInput<\n TProcedureInput,\n TInputWithoutCursorAndDirection = Omit<\n TProcedureInput,\n 'cursor' | 'direction'\n >,\n> = keyof TInputWithoutCursorAndDirection extends never\n ? undefined\n : DeepPartial<TInputWithoutCursorAndDirection> | undefined;\n\n/** @internal */\nexport type GetQueryProcedureInput<TProcedureInput> = TProcedureInput extends {\n cursor?: any;\n}\n ? GetInfiniteQueryInput<TProcedureInput>\n : DeepPartial<TProcedureInput> | undefined;\n\ntype GetParams<TProcedureOrRouter extends ProcedureOrRouter> =\n TProcedureOrRouter extends DecoratedQuery<infer $Def>\n ? [input?: GetQueryProcedureInput<$Def['input']>, type?: QueryType]\n : [];\n\n/**\n * Method to extract the query key for a procedure\n * @param procedureOrRouter - procedure or AnyRouter\n * @param input - input to procedureOrRouter\n * @param type - defaults to `any`\n * @see https://trpc.io/docs/v11/getQueryKey\n */\nexport function getQueryKey<TProcedureOrRouter extends ProcedureOrRouter>(\n procedureOrRouter: TProcedureOrRouter,\n ..._params: GetParams<TProcedureOrRouter>\n) {\n const [input, type] = _params;\n\n // @ts-expect-error - we don't expose _def on the type layer\n const path = procedureOrRouter._def().path as string[];\n const queryKey = getQueryKeyInternal(path, input, type ?? 'any');\n return queryKey;\n}\n\n// TODO: look over if we can't use a single type\nexport type QueryKeyKnown<TInput, TType extends Exclude<QueryType, 'any'>> = [\n string[],\n { input?: GetQueryProcedureInput<TInput>; type: TType }?,\n];\n\n/**\n * Method to extract the mutation key for a procedure\n * @param procedure - procedure\n * @see https://trpc.io/docs/v11/getQueryKey#mutations\n */\nexport function getMutationKey<TProcedure extends DecoratedMutation<any>>(\n procedure: TProcedure,\n) {\n // @ts-expect-error - we don't expose _def on the type layer\n const path = procedure._def().path as string[];\n return getMutationKeyInternal(path);\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAmDM,MAAA,YAAA,CAAA,UACA,WAAA;;;;;;AA3BN,SAAgB,oBACd,MACA,OACA,MACc;CAMd,MAAM,YAAY,KAAK,SAAS,SAAS,KAAK,MAAM,GAAG,CAAC;CAExD,IAAI,CAAC,UAAU,CAAC,QAAQ,SAAS,QAK/B,OAAO,UAAU,SAAS,CAAC,SAAS,IAAK,CAAC;CAG5C,IACE,SAAS,cACT,SAAS,KAAK,MACb,eAAe,SAAS,YAAY,QACrC;EACA,MAAM,EACJ,QAAQ,GACR,WAAW,OAAA;EAGb,OAAO,CACL,WACA;GACE,OAAA,yBAJA,OAAA,SAIoC;GACpC,MAAM;EACR,CACF;CACF;CACA,OAAO,CACL,WAAA,eAAA,eAAA,CAAA,GAEM,OAAO,UAAU,eACnB,UAAU,aAAa,EAAS,MAAM,CAAA,GACpC,QAAQ,SAAS,SAAS,EAAQ,KAAK,CAC7C,CACF;AACF;AAEA,SAAgB,uBAAuB,MAAyB;CAC9D,OAAO,oBAAoB,MAAM,KAAA,GAAW,KAAK;AACnD;;;;;;;;AA+BA,SAAgB,YACd,mBACA,GAAG,SACH;CACA,MAAM,CAAC,OAAO,QAAQ;CAGtB,MAAM,OAAO,kBAAkB,KAAK,CAAC,CAAC;CAEtC,OADiB,oBAAoB,MAAM,OAAO,SAAA,QAAA,SAAA,KAAA,IAAA,OAAQ,KAC5C;AAChB;;;;;;AAaA,SAAgB,eACd,WACA;CAEA,MAAM,OAAO,UAAU,KAAK,CAAC,CAAC;CAC9B,OAAO,uBAAuB,IAAI;AACpC"}
|
|
@@ -1,10 +1,8 @@
|
|
|
1
|
-
import * as _trpc_client1 from "@trpc/client";
|
|
2
1
|
import { CreateTRPCClientOptions, TRPCClient, TRPCClientError, TRPCClientErrorLike, TRPCRequestOptions, TRPCUntypedClient, createTRPCClient } from "@trpc/client";
|
|
3
|
-
import { CancelOptions, DataTag, DefinedInitialDataInfiniteOptions, DefinedInitialDataOptions, DefinedUseInfiniteQueryResult, DefinedUseQueryResult, FetchInfiniteQueryOptions, FetchQueryOptions, InfiniteData, InfiniteQueryObserverSuccessResult, InitialDataFunction, InvalidateOptions, InvalidateQueryFilters, MutationOptions, Query, QueryClient, QueryClientConfig, QueryFilters, QueryKey, QueryObserverSuccessResult, QueryOptions, RefetchOptions, RefetchQueryFilters, ResetOptions, SetDataOptions, SkipToken, UndefinedInitialDataInfiniteOptions, UndefinedInitialDataOptions, UnusedSkipTokenInfiniteOptions, UnusedSkipTokenOptions, Updater, UseBaseQueryOptions, UseInfiniteQueryOptions, UseInfiniteQueryResult, UseMutationOptions, UseMutationResult, UseQueryOptions, UseQueryResult, UseSuspenseInfiniteQueryOptions, UseSuspenseInfiniteQueryResult, UseSuspenseQueryOptions, UseSuspenseQueryResult } from "@tanstack/react-query";
|
|
4
2
|
import { AnyClientTypes, AnyMutationProcedure, AnyProcedure, AnyQueryProcedure, AnyRootTypes, AnyRouter, DeepPartial, DistributiveOmit, MaybePromise, ProcedureType, ProtectedIntersection, RouterRecord, Simplify, coerceAsyncIterableToArray, inferAsyncIterableYield, inferProcedureInput, inferProcedureOutput, inferTransformedProcedureOutput } from "@trpc/server/unstable-core-do-not-import";
|
|
3
|
+
import { CancelOptions, DataTag, DefinedInitialDataInfiniteOptions, DefinedInitialDataOptions, DefinedUseInfiniteQueryResult, DefinedUseQueryResult, FetchInfiniteQueryOptions, FetchQueryOptions, InfiniteData, InfiniteQueryObserverSuccessResult, InitialDataFunction, InvalidateOptions, InvalidateQueryFilters, MutationOptions, Query, QueryClient, QueryClientConfig, QueryFilters, QueryKey, QueryObserverSuccessResult, QueryOptions, RefetchOptions, RefetchQueryFilters, ResetOptions, SetDataOptions, SkipToken, UndefinedInitialDataInfiniteOptions, UndefinedInitialDataOptions, UnusedSkipTokenInfiniteOptions, UnusedSkipTokenOptions, Updater, UseBaseQueryOptions, UseInfiniteQueryOptions, UseInfiniteQueryResult, UseMutationOptions, UseMutationResult, UseQueryOptions, UseQueryResult, UseSuspenseInfiniteQueryOptions, UseSuspenseInfiniteQueryResult, UseSuspenseQueryOptions, UseSuspenseQueryResult } from "@tanstack/react-query";
|
|
5
4
|
import * as React$1 from "react";
|
|
6
5
|
import { JSX, ReactNode } from "react";
|
|
7
|
-
|
|
8
6
|
//#region src/internals/context.d.ts
|
|
9
7
|
interface TRPCUseUtilsOptions {
|
|
10
8
|
/**
|
|
@@ -68,21 +66,17 @@ interface TRPCQueryUtils<TRouter extends AnyRouter> {
|
|
|
68
66
|
/**
|
|
69
67
|
* @see https://tanstack.com/query/latest/docs/framework/react/reference/queryOptions#queryoptions
|
|
70
68
|
*/
|
|
71
|
-
queryOptions(path: readonly string[]
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
// <-- look into if needed
|
|
76
|
-
queryKey: TRPCQueryKey, opts: DefinedTRPCQueryOptionsIn<unknown, unknown, TRPCClientError<AnyClientTypes>>): DefinedTRPCQueryOptionsOut<unknown, unknown, TRPCClientError<AnyClientTypes>>;
|
|
69
|
+
queryOptions(path: readonly string[] // <-- look into if needed
|
|
70
|
+
, queryKey: TRPCQueryKey, opts?: UndefinedTRPCQueryOptionsIn<unknown, unknown, TRPCClientError<AnyClientTypes>>): UndefinedTRPCQueryOptionsOut<unknown, unknown, TRPCClientError<AnyClientTypes>>;
|
|
71
|
+
queryOptions(path: readonly string[] // <-- look into if needed
|
|
72
|
+
, queryKey: TRPCQueryKey, opts: DefinedTRPCQueryOptionsIn<unknown, unknown, TRPCClientError<AnyClientTypes>>): DefinedTRPCQueryOptionsOut<unknown, unknown, TRPCClientError<AnyClientTypes>>;
|
|
77
73
|
/**
|
|
78
74
|
* @see https://tanstack.com/query/latest/docs/framework/react/reference/infiniteQueryOptions#infinitequeryoptions
|
|
79
75
|
*/
|
|
80
|
-
infiniteQueryOptions(path: readonly string[]
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
// <-- look into if needed
|
|
85
|
-
queryKey: TRPCQueryKey, opts: DefinedTRPCInfiniteQueryOptionsIn<unknown, unknown, unknown, TRPCClientError<AnyClientTypes>>): DefinedTRPCInfiniteQueryOptionsOut<unknown, unknown, unknown, TRPCClientError<AnyClientTypes>>;
|
|
76
|
+
infiniteQueryOptions(path: readonly string[] // <-- look into if needed
|
|
77
|
+
, queryKey: TRPCQueryKey, opts: UndefinedTRPCInfiniteQueryOptionsIn<unknown, unknown, unknown, TRPCClientError<AnyClientTypes>>): UndefinedTRPCInfiniteQueryOptionsOut<unknown, unknown, unknown, TRPCClientError<AnyClientTypes>>;
|
|
78
|
+
infiniteQueryOptions(path: readonly string[] // <-- look into if needed
|
|
79
|
+
, queryKey: TRPCQueryKey, opts: DefinedTRPCInfiniteQueryOptionsIn<unknown, unknown, unknown, TRPCClientError<AnyClientTypes>>): DefinedTRPCInfiniteQueryOptionsOut<unknown, unknown, unknown, TRPCClientError<AnyClientTypes>>;
|
|
86
80
|
/**
|
|
87
81
|
* @see https://tanstack.com/query/v5/docs/reference/QueryClient#queryclientfetchquery
|
|
88
82
|
*/
|
|
@@ -299,7 +293,6 @@ interface TRPCHookResult {
|
|
|
299
293
|
path: string;
|
|
300
294
|
};
|
|
301
295
|
}
|
|
302
|
-
//# sourceMappingURL=types.d.ts.map
|
|
303
296
|
//#endregion
|
|
304
297
|
//#region src/shared/types.d.ts
|
|
305
298
|
interface TRPCQueryBaseOptions {
|
|
@@ -398,7 +391,7 @@ interface CreateTRPCReactOptions<_TRouter extends AnyRouter> {
|
|
|
398
391
|
*/
|
|
399
392
|
declare function createRootHooks<TRouter extends AnyRouter, TSSRContext = unknown>(config?: CreateTRPCReactOptions<TRouter>): {
|
|
400
393
|
Provider: TRPCProvider<TRouter, TSSRContext>;
|
|
401
|
-
createClient: (opts:
|
|
394
|
+
createClient: (opts: import("@trpc/client").CreateTRPCClientOptions<TRouter>) => import("@trpc/client").TRPCClient<TRouter>;
|
|
402
395
|
useContext: () => TRPCContextState<TRouter, TSSRContext>;
|
|
403
396
|
useUtils: () => TRPCContextState<TRouter, TSSRContext>;
|
|
404
397
|
useQuery: (path: readonly string[], input: unknown, opts?: UseTRPCQueryOptions<unknown, unknown, TRPCClientErrorLike<TRouter>>) => UseTRPCQueryResult<unknown, TRPCClientErrorLike<TRouter>>;
|
|
@@ -417,7 +410,6 @@ declare function createRootHooks<TRouter extends AnyRouter, TSSRContext = unknow
|
|
|
417
410
|
* @internal
|
|
418
411
|
*/
|
|
419
412
|
type CreateReactQueryHooks<TRouter extends AnyRouter, TSSRContext = unknown> = ReturnType<typeof createRootHooks<TRouter, TSSRContext>>;
|
|
420
|
-
//# sourceMappingURL=createHooksInternal.d.ts.map
|
|
421
413
|
//#endregion
|
|
422
414
|
//#region src/shared/proxy/decorationProxy.d.ts
|
|
423
415
|
/**
|
|
@@ -425,7 +417,6 @@ type CreateReactQueryHooks<TRouter extends AnyRouter, TSSRContext = unknown> = R
|
|
|
425
417
|
* @internal
|
|
426
418
|
*/
|
|
427
419
|
declare function createReactDecoration<TRouter extends AnyRouter, TSSRContext = unknown>(hooks: CreateReactQueryHooks<TRouter, TSSRContext>): unknown;
|
|
428
|
-
//# sourceMappingURL=decorationProxy.d.ts.map
|
|
429
420
|
//#endregion
|
|
430
421
|
//#region src/utils/inferReactQueryProcedure.d.ts
|
|
431
422
|
/**
|
|
@@ -444,7 +435,7 @@ type InferQueryResult<TRoot extends AnyRootTypes, TProcedure extends AnyProcedur
|
|
|
444
435
|
* @internal
|
|
445
436
|
*/
|
|
446
437
|
type InferMutationResult<TRoot extends AnyRootTypes, TProcedure extends AnyProcedure, TContext = unknown> = UseTRPCMutationResult<inferTransformedProcedureOutput<TRoot, TProcedure>, TRPCClientErrorLike<TRoot>, inferProcedureInput<TProcedure>, TContext>;
|
|
447
|
-
type inferReactQueryProcedureOptionsInner<TRoot extends AnyRootTypes, TRecord extends RouterRecord> = { [TKey in keyof TRecord]: TRecord[TKey] extends infer $Value ? $Value extends AnyQueryProcedure ? InferQueryOptions<TRoot, $Value> : $Value extends AnyMutationProcedure ? InferMutationOptions<TRoot, $Value> : $Value extends RouterRecord ? inferReactQueryProcedureOptionsInner<TRoot, $Value> : never : never };
|
|
438
|
+
type inferReactQueryProcedureOptionsInner<TRoot extends AnyRootTypes, TRecord extends RouterRecord> = { [TKey in keyof TRecord]: TRecord[TKey] extends (infer $Value) ? $Value extends AnyQueryProcedure ? InferQueryOptions<TRoot, $Value> : $Value extends AnyMutationProcedure ? InferMutationOptions<TRoot, $Value> : $Value extends RouterRecord ? inferReactQueryProcedureOptionsInner<TRoot, $Value> : never : never; };
|
|
448
439
|
type inferReactQueryProcedureOptions<TRouter extends AnyRouter> = inferReactQueryProcedureOptionsInner<TRouter['_def']['_config']['$types'], TRouter['_def']['record']>;
|
|
449
440
|
//#endregion
|
|
450
441
|
//#region src/shared/proxy/utilsProxy.d.ts
|
|
@@ -564,7 +555,7 @@ type DecorateRouter = {
|
|
|
564
555
|
/**
|
|
565
556
|
* @internal
|
|
566
557
|
*/
|
|
567
|
-
type DecoratedProcedureUtilsRecord<TRoot extends AnyRootTypes, TRecord extends RouterRecord> = DecorateRouter & { [TKey in keyof TRecord]: TRecord[TKey] extends infer $Value ? $Value extends AnyQueryProcedure ? DecorateQueryProcedure<TRoot, $Value> : $Value extends AnyMutationProcedure ? DecorateMutationProcedure<TRoot, $Value> : $Value extends RouterRecord ? DecoratedProcedureUtilsRecord<TRoot, $Value> & DecorateRouter : never : never };
|
|
558
|
+
type DecoratedProcedureUtilsRecord<TRoot extends AnyRootTypes, TRecord extends RouterRecord> = DecorateRouter & { [TKey in keyof TRecord]: TRecord[TKey] extends (infer $Value) ? $Value extends AnyQueryProcedure ? DecorateQueryProcedure<TRoot, $Value> : $Value extends AnyMutationProcedure ? DecorateMutationProcedure<TRoot, $Value> : $Value extends RouterRecord ? DecoratedProcedureUtilsRecord<TRoot, $Value> & DecorateRouter : never : never; };
|
|
568
559
|
type AnyDecoratedProcedure = DecorateQueryProcedure<any, any> & DecorateMutationProcedure<any, any>;
|
|
569
560
|
type CreateReactUtils<TRouter extends AnyRouter, TSSRContext> = ProtectedIntersection<DecoratedTRPCContextProps<TRouter, TSSRContext>, DecoratedProcedureUtilsRecord<TRouter['_def']['_config']['$types'], TRouter['_def']['record']>>;
|
|
570
561
|
type CreateQueryUtils<TRouter extends AnyRouter> = DecoratedProcedureUtilsRecord<TRouter['_def']['_config']['$types'], TRouter['_def']['record']>;
|
|
@@ -583,12 +574,12 @@ type GetQueryOptions<TRoot extends AnyRootTypes, TProcedure extends AnyProcedure
|
|
|
583
574
|
/**
|
|
584
575
|
* @internal
|
|
585
576
|
*/
|
|
586
|
-
type UseQueriesProcedureRecord<TRoot extends AnyRootTypes, TRecord extends RouterRecord> = { [TKey in keyof TRecord]: TRecord[TKey] extends infer $Value ? $Value extends AnyQueryProcedure ? GetQueryOptions<TRoot, $Value> : $Value extends RouterRecord ? UseQueriesProcedureRecord<TRoot, $Value> : never : never };
|
|
577
|
+
type UseQueriesProcedureRecord<TRoot extends AnyRootTypes, TRecord extends RouterRecord> = { [TKey in keyof TRecord]: TRecord[TKey] extends (infer $Value) ? $Value extends AnyQueryProcedure ? GetQueryOptions<TRoot, $Value> : $Value extends RouterRecord ? UseQueriesProcedureRecord<TRoot, $Value> : never : never; };
|
|
587
578
|
type GetSuspenseQueryOptions<TRoot extends AnyRootTypes, TProcedure extends AnyQueryProcedure> = <TData = inferTransformedProcedureOutput<TRoot, TProcedure>>(input: inferProcedureInput<TProcedure>, opts?: TrpcQueryOptionsForUseSuspenseQueries<inferTransformedProcedureOutput<TRoot, TProcedure>, TData, TRPCClientError<TRoot>>) => TrpcQueryOptionsForUseSuspenseQueries<inferTransformedProcedureOutput<TRoot, TProcedure>, TData, TRPCClientError<TRoot>>;
|
|
588
579
|
/**
|
|
589
580
|
* @internal
|
|
590
581
|
*/
|
|
591
|
-
type UseSuspenseQueriesProcedureRecord<TRoot extends AnyRootTypes, TRecord extends RouterRecord> = { [TKey in keyof TRecord]: TRecord[TKey] extends infer $Value ? $Value extends AnyQueryProcedure ? GetSuspenseQueryOptions<TRoot, $Value> : $Value extends RouterRecord ? UseSuspenseQueriesProcedureRecord<TRoot, $Value> : never : never };
|
|
582
|
+
type UseSuspenseQueriesProcedureRecord<TRoot extends AnyRootTypes, TRecord extends RouterRecord> = { [TKey in keyof TRecord]: TRecord[TKey] extends (infer $Value) ? $Value extends AnyQueryProcedure ? GetSuspenseQueryOptions<TRoot, $Value> : $Value extends RouterRecord ? UseSuspenseQueriesProcedureRecord<TRoot, $Value> : never : never; };
|
|
592
583
|
/**
|
|
593
584
|
* Create proxy for `useQueries` options
|
|
594
585
|
* @internal
|
|
@@ -610,7 +601,6 @@ type CreateTRPCReactQueryClientConfig = {
|
|
|
610
601
|
* @internal
|
|
611
602
|
*/
|
|
612
603
|
declare const getQueryClient: (config: CreateTRPCReactQueryClientConfig) => QueryClient;
|
|
613
|
-
//# sourceMappingURL=queryClient.d.ts.map
|
|
614
604
|
//#endregion
|
|
615
605
|
//#region src/shared/polymorphism/mutationLike.d.ts
|
|
616
606
|
/**
|
|
@@ -627,7 +617,6 @@ type InferMutationLikeInput<TMutationLike extends MutationLike<any, any>> = TMut
|
|
|
627
617
|
* Use to unwrap a MutationLike's data output
|
|
628
618
|
*/
|
|
629
619
|
type InferMutationLikeData<TMutationLike extends MutationLike<any, any>> = TMutationLike extends MutationLike<infer TRoot, infer TProcedure> ? inferTransformedProcedureOutput<TRoot, TProcedure> : never;
|
|
630
|
-
//# sourceMappingURL=mutationLike.d.ts.map
|
|
631
620
|
//#endregion
|
|
632
621
|
//#region src/shared/polymorphism/queryLike.d.ts
|
|
633
622
|
/**
|
|
@@ -645,22 +634,19 @@ type InferQueryLikeInput<TQueryLike> = TQueryLike extends DecoratedQuery<infer $
|
|
|
645
634
|
* Use to unwrap a QueryLike's data output
|
|
646
635
|
*/
|
|
647
636
|
type InferQueryLikeData<TQueryLike> = TQueryLike extends DecoratedQuery<infer $Def> ? $Def['output'] : TQueryLike extends QueryLike<infer TRoot, infer TProcedure> ? inferTransformedProcedureOutput<TRoot, TProcedure> : never;
|
|
648
|
-
//# sourceMappingURL=queryLike.d.ts.map
|
|
649
637
|
//#endregion
|
|
650
638
|
//#region src/shared/polymorphism/routerLike.d.ts
|
|
651
639
|
/**
|
|
652
640
|
* Use to describe a route path which matches a given route's interface
|
|
653
641
|
*/
|
|
654
642
|
type RouterLike<TRouter extends AnyRouter> = RouterLikeInner<TRouter['_def']['_config']['$types'], TRouter['_def']['record']>;
|
|
655
|
-
type RouterLikeInner<TRoot extends AnyRootTypes, TRecord extends RouterRecord> = { [TKey in keyof TRecord]: TRecord[TKey] extends infer $Value ? $Value extends AnyQueryProcedure ? QueryLike<TRoot, $Value> : $Value extends AnyMutationProcedure ? MutationLike<TRoot, $Value> : $Value extends RouterRecord ? RouterLikeInner<TRoot, $Value> : never : never };
|
|
656
|
-
//# sourceMappingURL=routerLike.d.ts.map
|
|
643
|
+
type RouterLikeInner<TRoot extends AnyRootTypes, TRecord extends RouterRecord> = { [TKey in keyof TRecord]: TRecord[TKey] extends (infer $Value) ? $Value extends AnyQueryProcedure ? QueryLike<TRoot, $Value> : $Value extends AnyMutationProcedure ? MutationLike<TRoot, $Value> : $Value extends RouterRecord ? RouterLikeInner<TRoot, $Value> : never : never; };
|
|
657
644
|
//#endregion
|
|
658
645
|
//#region src/shared/polymorphism/utilsLike.d.ts
|
|
659
646
|
/**
|
|
660
647
|
* Use to describe a Utils/Context path which matches the given route's interface
|
|
661
648
|
*/
|
|
662
649
|
type UtilsLike<TRouter extends AnyRouter> = DecoratedProcedureUtilsRecord<TRouter['_def']['_config']['$types'], TRouter['_def']['record']>;
|
|
663
|
-
//# sourceMappingURL=utilsLike.d.ts.map
|
|
664
650
|
//#endregion
|
|
665
651
|
//#region src/internals/getClientArgs.d.ts
|
|
666
652
|
/**
|
|
@@ -670,7 +656,6 @@ declare function getClientArgs<TOptions>(queryKey: TRPCQueryKey, opts: TOptions,
|
|
|
670
656
|
pageParam: any;
|
|
671
657
|
direction: 'forward' | 'backward';
|
|
672
658
|
}): readonly [string, unknown, any];
|
|
673
|
-
//# sourceMappingURL=getClientArgs.d.ts.map
|
|
674
659
|
//#endregion
|
|
675
660
|
//#region src/internals/useQueries.d.ts
|
|
676
661
|
/**
|
|
@@ -692,11 +677,11 @@ type TrpcQueryOptionsForUseSuspenseQueries<TOutput, TData, TError> = Distributiv
|
|
|
692
677
|
/**
|
|
693
678
|
* @internal
|
|
694
679
|
*/
|
|
695
|
-
declare type QueriesResults<TQueriesOptions extends UseQueryOptionsForUseQueries<any, any, any, any>[]> = { [TKey in keyof TQueriesOptions]: TQueriesOptions[TKey] extends UseQueryOptionsForUseQueries<infer TQueryFnData, infer TError, infer TData, any> ? UseTRPCQueryResult<unknown extends TData ? TQueryFnData : TData, TError> : never };
|
|
680
|
+
declare type QueriesResults<TQueriesOptions extends UseQueryOptionsForUseQueries<any, any, any, any>[]> = { [TKey in keyof TQueriesOptions]: TQueriesOptions[TKey] extends UseQueryOptionsForUseQueries<infer TQueryFnData, infer TError, infer TData, any> ? UseTRPCQueryResult<unknown extends TData ? TQueryFnData : TData, TError> : never; };
|
|
696
681
|
/**
|
|
697
682
|
* @internal
|
|
698
683
|
*/
|
|
699
|
-
declare type SuspenseQueriesResults<TQueriesOptions extends UseQueryOptionsForUseSuspenseQueries<any, any, any, any>[]> = [{ [TKey in keyof TQueriesOptions]: TQueriesOptions[TKey] extends UseQueryOptionsForUseSuspenseQueries<infer TQueryFnData, any, infer TData, any> ? unknown extends TData ? TQueryFnData : TData : never }, { [TKey in keyof TQueriesOptions]: TQueriesOptions[TKey] extends UseQueryOptionsForUseSuspenseQueries<infer TQueryFnData, infer TError, infer TData, any> ? UseSuspenseQueryResult<unknown extends TData ? TQueryFnData : TData, TError> : never }];
|
|
684
|
+
declare type SuspenseQueriesResults<TQueriesOptions extends UseQueryOptionsForUseSuspenseQueries<any, any, any, any>[]> = [{ [TKey in keyof TQueriesOptions]: TQueriesOptions[TKey] extends UseQueryOptionsForUseSuspenseQueries<infer TQueryFnData, any, infer TData, any> ? unknown extends TData ? TQueryFnData : TData : never; }, { [TKey in keyof TQueriesOptions]: TQueriesOptions[TKey] extends UseQueryOptionsForUseSuspenseQueries<infer TQueryFnData, infer TError, infer TData, any> ? UseSuspenseQueryResult<unknown extends TData ? TQueryFnData : TData, TError> : never; }];
|
|
700
685
|
type GetOptions<TQueryOptions> = TQueryOptions extends UseQueryOptionsForUseQueries<any, any, any, any> ? TQueryOptions : never;
|
|
701
686
|
/**
|
|
702
687
|
* @internal
|
|
@@ -817,12 +802,12 @@ type DecorateProcedure<TType extends ProcedureType, TDef extends ResolverDef> =
|
|
|
817
802
|
/**
|
|
818
803
|
* @internal
|
|
819
804
|
*/
|
|
820
|
-
type DecorateRouterRecord<TRoot extends AnyRootTypes, TRecord extends RouterRecord> = { [TKey in keyof TRecord]: TRecord[TKey] extends infer $Value ? $Value extends AnyProcedure ? DecorateProcedure<$Value['_def']['type'], {
|
|
805
|
+
type DecorateRouterRecord<TRoot extends AnyRootTypes, TRecord extends RouterRecord> = { [TKey in keyof TRecord]: TRecord[TKey] extends (infer $Value) ? $Value extends AnyProcedure ? DecorateProcedure<$Value['_def']['type'], {
|
|
821
806
|
input: inferProcedureInput<$Value>;
|
|
822
807
|
output: inferTransformedProcedureOutput<TRoot, $Value>;
|
|
823
808
|
transformer: TRoot['transformer'];
|
|
824
809
|
errorShape: TRoot['errorShape'];
|
|
825
|
-
}> : $Value extends RouterRecord ? DecorateRouterRecord<TRoot, $Value> : never : never };
|
|
810
|
+
}> : $Value extends RouterRecord ? DecorateRouterRecord<TRoot, $Value> : never : never; };
|
|
826
811
|
/**
|
|
827
812
|
* @internal
|
|
828
813
|
*/
|
|
@@ -843,10 +828,6 @@ type CreateTRPCReactBase<TRouter extends AnyRouter, TSSRContext> = {
|
|
|
843
828
|
useSuspenseQueries: TRPCUseSuspenseQueries<TRouter>;
|
|
844
829
|
};
|
|
845
830
|
type CreateTRPCReact<TRouter extends AnyRouter, TSSRContext> = ProtectedIntersection<CreateTRPCReactBase<TRouter, TSSRContext>, DecorateRouterRecord<TRouter['_def']['_config']['$types'], TRouter['_def']['record']>>;
|
|
846
|
-
/**
|
|
847
|
-
* @internal
|
|
848
|
-
*/
|
|
849
|
-
|
|
850
831
|
declare function createTRPCReact<TRouter extends AnyRouter, TSSRContext = unknown>(opts?: CreateTRPCReactOptions<TRouter>): CreateTRPCReact<TRouter, TSSRContext>;
|
|
851
832
|
//#endregion
|
|
852
833
|
//#region src/internals/getQueryKey.d.ts
|
|
@@ -857,12 +838,6 @@ type TRPCQueryKey = [readonly string[], {
|
|
|
857
838
|
}?];
|
|
858
839
|
type TRPCMutationKey = [readonly string[]];
|
|
859
840
|
type ProcedureOrRouter = DecoratedMutation<any> | DecoratedQuery<any> | DecorateRouterRecord<any, any>;
|
|
860
|
-
/**
|
|
861
|
-
* To allow easy interactions with groups of related queries, such as
|
|
862
|
-
* invalidating all queries of a router, we use an array as the path when
|
|
863
|
-
* storing in tanstack query.
|
|
864
|
-
**/
|
|
865
|
-
|
|
866
841
|
type GetInfiniteQueryInput<TProcedureInput, TInputWithoutCursorAndDirection = Omit<TProcedureInput, 'cursor' | 'direction'>> = keyof TInputWithoutCursorAndDirection extends never ? undefined : DeepPartial<TInputWithoutCursorAndDirection> | undefined;
|
|
867
842
|
/** @internal */
|
|
868
843
|
type GetQueryProcedureInput<TProcedureInput> = TProcedureInput extends {
|
|
@@ -888,5 +863,5 @@ type QueryKeyKnown<TInput, TType extends Exclude<QueryType, 'any'>> = [string[],
|
|
|
888
863
|
*/
|
|
889
864
|
declare function getMutationKey<TProcedure extends DecoratedMutation<any>>(procedure: TProcedure): TRPCMutationKey;
|
|
890
865
|
//#endregion
|
|
891
|
-
export {
|
|
892
|
-
//# sourceMappingURL=getQueryKey
|
|
866
|
+
export { DefinedUseTRPCQueryResult as $, createReactQueryUtils as A, SSRState as At, TRPCQueryBaseOptions as B, UseSuspenseQueriesProcedureRecord as C, UseTRPCQuerySuccessResult as Ct, DecorateQueryProcedure as D, UseTRPCSuspenseQueryOptions as Dt, CreateReactUtils as E, UseTRPCSuspenseInfiniteQueryResult as Et, CreateTRPCReactOptions as F, TRPCFetchInfiniteQueryOptions as Ft, UndefinedTRPCQueryOptionsOut as G, UndefinedTRPCInfiniteQueryOptionsIn as H, DefinedTRPCInfiniteQueryOptionsIn as I, TRPCFetchQueryOptions as It, UnusedSkipTokenTRPCQueryOptionsIn as J, UnusedSkipTokenTRPCInfiniteQueryOptionsIn as K, DefinedTRPCInfiniteQueryOptionsOut as L, TRPCQueryUtils as Lt, inferReactQueryProcedureOptions as M, TRPCContextProps as Mt, createReactDecoration as N, TRPCContextPropsBase as Nt, DecoratedProcedureUtilsRecord as O, UseTRPCSuspenseQueryResult as Ot, createRootHooks as P, TRPCContextState as Pt, DefinedUseTRPCQueryOptions as Q, DefinedTRPCQueryOptionsIn as R, contextProps as Rt, UseQueriesProcedureRecord as S, UseTRPCQueryResult as St, CreateQueryUtils as T, UseTRPCSuspenseInfiniteQueryOptions as Tt, UndefinedTRPCInfiniteQueryOptionsOut as U, TRPCQueryOptionsResult as V, UndefinedTRPCQueryOptionsIn as W, UseMutationOverride as X, UnusedSkipTokenTRPCQueryOptionsOut as Y, CreateClient as Z, InferMutationLikeData as _, UseTRPCMutationOptions as _t, DecorateProcedure as a, TRPCQueryOptions as at, CreateTRPCReactQueryClientConfig as b, UseTRPCPrefetchQueryOptions as bt, TRPCUseQueries as c, TRPCSubscriptionConnectingResult as ct, UtilsLike as d, TRPCSubscriptionPendingResult as dt, ExtractCursorType as et, RouterLike as f, TRPCSubscriptionResult as ft, QueryLike as g, UseTRPCInfiniteQuerySuccessResult as gt, InferQueryLikeInput as h, UseTRPCInfiniteQueryResult as ht, CreateTRPCReactBase as i, TRPCProviderProps as it, getQueryType as j, TRPCContext as jt, createQueryUtilsProxy as k, DecoratedTRPCContextProps as kt, TRPCUseSuspenseQueries as l, TRPCSubscriptionErrorResult as lt, InferQueryLikeData as m, UseTRPCInfiniteQueryOptions as mt, getQueryKey as n, TRPCHookResult as nt, DecorateRouterRecord as o, TRPCReactRequestOptions as ot, RouterLikeInner as p, TRPCUseQueryBaseOptions as pt, UnusedSkipTokenTRPCInfiniteQueryOptionsOut as q, CreateTRPCReact as r, TRPCProvider as rt, createTRPCReact as s, TRPCSubscriptionBaseResult as st, getMutationKey as t, OutputWithCursor as tt, getClientArgs as u, TRPCSubscriptionIdleResult as ut, InferMutationLikeInput as v, UseTRPCMutationResult as vt, createUseQueries as w, UseTRPCSubscriptionOptions as wt, getQueryClient as x, UseTRPCQueryOptions as xt, MutationLike as y, UseTRPCPrefetchInfiniteQueryOptions as yt, DefinedTRPCQueryOptionsOut as z };
|
|
867
|
+
//# sourceMappingURL=getQueryKey-Bw7DtJ4y.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"getQueryKey-Bw7DtJ4y.d.cts","names":[],"sources":["../src/internals/context.tsx","../src/shared/hooks/types.ts","../src/shared/types.ts","../src/shared/hooks/createHooksInternal.tsx","../src/shared/proxy/decorationProxy.ts","../src/utils/inferReactQueryProcedure.ts","../src/shared/proxy/utilsProxy.ts","../src/shared/proxy/useQueriesProxy.ts","../src/shared/queryClient.ts","../src/shared/polymorphism/mutationLike.ts","../src/shared/polymorphism/queryLike.ts","../src/shared/polymorphism/routerLike.ts","../src/shared/polymorphism/utilsLike.ts","../src/internals/getClientArgs.ts","../src/internals/useQueries.ts","../src/createTRPCReact.tsx","../src/internals/getQueryKey.ts"],"mappings":";;;;;;UA0CU;;;;EAIR,OAAO;;UAEQ,sBAAsB,SAAS,gBAE5C,iBAAiB,kBAAkB,SAAS,sBAC5C;KAIQ,8BAA8B,QAAQ,SAAS,UACzD,iBACE,0BACE,SACA,QACA,SACA,cACA,kBAAkB,6CAIpB;EACE,gBAAgB,kBAAkB;;;KAI5B;UAEK,qBAAqB,gBAAgB,WAAW;;;;EAI/D,QAAQ,kBAAkB;;;;;EAK1B,aAAa;;;;;;;;;EASb,WAAW;;;;;;EAMX;;;;;KAMU,0BACV,gBAAgB,WAChB,eACE,qBAAqB,SAAS;EAChC,QAAQ,WAAW;;UAGJ,iBACf,gBAAgB,WAChB,qBACQ,qBAAqB,SAAS;;;;EAItC,aAAa;;cAGF,qBAAqB;;;;UAUjB,iBACf,gBAAgB,WAChB,iCAGE,SAAS,iBAAiB,SAAS,eACnC,eAAe;;;;UAKF,eAAe,gBAAgB;;;;EAI9C,aACE;IACA,UAAU,cACV,OAAO,8CAGL,gBAAgB,mBAEjB,+CAGD,gBAAgB;EAElB,aACE;IACA,UAAU,cACV,MAAM,4CAGJ,gBAAgB,mBAEj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