@trpc/react-query 11.1.3-canary.4 → 11.1.3

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.
@@ -1 +1 @@
1
- {"version":3,"file":"createHooksInternal.d.ts","sourceRoot":"","sources":["../../../src/shared/hooks/createHooksInternal.tsx"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,cAAc,CAAC;AAOxD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,0CAA0C,CAAC;AAG1E,OAAO,KAAK,EAAY,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAY1E,OAAO,KAAK,EACV,cAAc,EACd,sBAAsB,EACvB,MAAM,4BAA4B,CAAC;AAGpC,OAAO,KAAK,EAAE,sBAAsB,EAAuB,MAAM,UAAU,CAAC;AAC5E,OAAO,KAAK,EACV,YAAY,EAIZ,sBAAsB,EACtB,2BAA2B,EAC3B,0BAA0B,EAC1B,sBAAsB,EACtB,qBAAqB,EACrB,mCAAmC,EACnC,2BAA2B,EAC3B,mBAAmB,EACnB,kBAAkB,EAClB,0BAA0B,EAC1B,mCAAmC,EACnC,kCAAkC,EAClC,2BAA2B,EAC3B,0BAA0B,EAC3B,MAAM,SAAS,CAAC;AAgBjB;;GAEG;AACH,wBAAgB,eAAe,CAC7B,OAAO,SAAS,SAAS,EACzB,WAAW,GAAG,OAAO,EACrB,MAAM,CAAC,EAAE,sBAAsB,CAAC,OAAO,CAAC;;;;;qBAsFhC,SAAS,MAAM,EAAE,SAChB,OAAO,SACP,mBAAmB,CAAC,OAAO,EAAE,OAAO,+BAAS,KACnD,kBAAkB,CAAC,OAAO,+BAAS;6BAsE9B,MAAM,EAAE,SACP,OAAO,SACP,2BAA2B,CAAC,OAAO,EAAE,OAAO,+BAAS,KAC3D,IAAI;6BAgCC,SAAS,MAAM,EAAE,SAChB,OAAO,SACP,2BAA2B,CAAC,OAAO,EAAE,OAAO,+BAAS,KAC3D,0BAA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;AAED;;;GAGG;AACH,MAAM,MAAM,qBAAqB,CAC/B,OAAO,SAAS,SAAS,EACzB,WAAW,GAAG,OAAO,IACnB,UAAU,CAAC,OAAO,eAAe,CAAC,OAAO,EAAE,WAAW,CAAC,CAAC,CAAC"}
@@ -30,6 +30,7 @@ function _interopNamespaceDefault(e) {
30
30
 
31
31
  var React__namespace = /*#__PURE__*/_interopNamespaceDefault(React);
32
32
 
33
+ // TODO: Look into fixing react-compiler support
33
34
  const trackResult = (result, onTrackResult)=>{
34
35
  const trackedResult = new Proxy(result, {
35
36
  get (target, prop) {
@@ -9,6 +9,7 @@ import { useHookResult, buildQueryFromAsyncIterable } from '../../internals/trpc
9
9
  import { createUtilityFunctions } from '../../utils/createUtilityFunctions.mjs';
10
10
  import { createUseQueries } from '../proxy/useQueriesProxy.mjs';
11
11
 
12
+ // TODO: Look into fixing react-compiler support
12
13
  const trackResult = (result, onTrackResult)=>{
13
14
  const trackedResult = new Proxy(result, {
14
15
  get (target, prop) {
@@ -22,7 +22,7 @@ var unstableCoreDoNotImport = require('@trpc/server/unstable-core-do-not-import'
22
22
  };
23
23
  }
24
24
  const [input, ...rest] = args;
25
- const opts = rest[0] || {};
25
+ const opts = rest[0] ?? {};
26
26
  return hooks[lastArg](pathCopy, input, opts);
27
27
  });
28
28
  }
@@ -20,7 +20,7 @@ import { createRecursiveProxy } from '@trpc/server/unstable-core-do-not-import';
20
20
  };
21
21
  }
22
22
  const [input, ...rest] = args;
23
- const opts = rest[0] || {};
23
+ const opts = rest[0] ?? {};
24
24
  return hooks[lastArg](pathCopy, input, opts);
25
25
  });
26
26
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@trpc/react-query",
3
- "version": "11.1.3-canary.4+cf7091a95",
3
+ "version": "11.1.3",
4
4
  "description": "The tRPC React library",
5
5
  "author": "KATT",
6
6
  "license": "MIT",
@@ -67,8 +67,8 @@
67
67
  },
68
68
  "peerDependencies": {
69
69
  "@tanstack/react-query": "^5.67.1",
70
- "@trpc/client": "11.1.3-canary.4+cf7091a95",
71
- "@trpc/server": "11.1.3-canary.4+cf7091a95",
70
+ "@trpc/client": "11.1.3",
71
+ "@trpc/server": "11.1.3",
72
72
  "react": ">=18.2.0",
73
73
  "react-dom": ">=18.2.0",
74
74
  "typescript": ">=5.7.2"
@@ -81,12 +81,12 @@
81
81
  "@testing-library/jest-dom": "^6.0.0",
82
82
  "@testing-library/react": "^16.1.0",
83
83
  "@testing-library/user-event": "^14.4.3",
84
- "@trpc/client": "11.1.3-canary.4+cf7091a95",
85
- "@trpc/server": "11.1.3-canary.4+cf7091a95",
84
+ "@trpc/client": "11.1.3",
85
+ "@trpc/server": "11.1.3",
86
86
  "@types/express": "^5.0.0",
87
87
  "@types/node": "^22.13.5",
88
88
  "@types/react": "^19.1.0",
89
- "eslint": "^9.21.0",
89
+ "eslint": "^9.26.0",
90
90
  "express": "^5.0.0",
91
91
  "next": "^15.3.1",
92
92
  "react": "^19.1.0",
@@ -104,5 +104,5 @@
104
104
  "funding": [
105
105
  "https://trpc.io/sponsor"
106
106
  ],
107
- "gitHead": "cf7091a95bb216c595b7eeb28d54dbcb217e3359"
107
+ "gitHead": "136b18fc55fece9b8f06d4a17780cff7f55cabf5"
108
108
  }
@@ -1,3 +1,5 @@
1
+ // TODO: Look into fixing react-compiler support
2
+ /* eslint-disable react-hooks/react-compiler */
1
3
  import {
2
4
  useInfiniteQuery as __useInfiniteQuery,
3
5
  useMutation as __useMutation,
@@ -28,7 +28,7 @@ export function createReactDecoration<
28
28
  }
29
29
 
30
30
  const [input, ...rest] = args;
31
- const opts = rest[0] || {};
31
+ const opts = rest[0] ?? {};
32
32
 
33
33
  return (hooks as any)[lastArg](pathCopy, input, opts);
34
34
  });
@@ -1,258 +0,0 @@
1
- {
2
- "bundleSize": 45528,
3
- "bundleOrigSize": 93615,
4
- "bundleReduction": 51.37,
5
- "modules": [
6
- {
7
- "id": "/src/shared/hooks/createHooksInternal.tsx",
8
- "size": 20346,
9
- "origSize": 22218,
10
- "renderedExports": [
11
- "createRootHooks"
12
- ],
13
- "removedExports": [],
14
- "dependents": [
15
- "/src/createTRPCReact.tsx"
16
- ],
17
- "percent": 44.69,
18
- "reduction": 8.43
19
- },
20
- {
21
- "id": "/src/utils/createUtilityFunctions.ts",
22
- "size": 7226,
23
- "origSize": 7495,
24
- "renderedExports": [
25
- "createUtilityFunctions"
26
- ],
27
- "removedExports": [],
28
- "dependents": [
29
- "/src/createTRPCQueryUtils.tsx",
30
- "/src/shared/hooks/createHooksInternal.tsx"
31
- ],
32
- "percent": 15.87,
33
- "reduction": 3.59
34
- },
35
- {
36
- "id": "/src/server/ssgProxy.ts",
37
- "size": 4461,
38
- "origSize": 6440,
39
- "renderedExports": [
40
- "createServerSideHelpers"
41
- ],
42
- "removedExports": [],
43
- "dependents": [
44
- "/src/server/index.ts"
45
- ],
46
- "percent": 9.8,
47
- "reduction": 30.73
48
- },
49
- {
50
- "id": "/src/shared/proxy/utilsProxy.ts",
51
- "size": 3628,
52
- "origSize": 16612,
53
- "renderedExports": [
54
- "getQueryType",
55
- "createReactQueryUtils",
56
- "createQueryUtilsProxy"
57
- ],
58
- "removedExports": [],
59
- "dependents": [
60
- "/src/shared/index.ts"
61
- ],
62
- "percent": 7.97,
63
- "reduction": 78.16
64
- },
65
- {
66
- "id": "/src/rsc.tsx",
67
- "size": 3230,
68
- "origSize": 5395,
69
- "renderedExports": [
70
- "createHydrationHelpers"
71
- ],
72
- "removedExports": [],
73
- "dependents": [],
74
- "percent": 7.09,
75
- "reduction": 40.13
76
- },
77
- {
78
- "id": "/src/internals/getQueryKey.ts",
79
- "size": 2502,
80
- "origSize": 4189,
81
- "renderedExports": [
82
- "getQueryKeyInternal",
83
- "getMutationKeyInternal",
84
- "getQueryKey",
85
- "getMutationKey"
86
- ],
87
- "removedExports": [],
88
- "dependents": [
89
- "/src/index.ts",
90
- "/src/rsc.tsx",
91
- "/src/shared/proxy/utilsProxy.ts",
92
- "/src/shared/proxy/useQueriesProxy.ts",
93
- "/src/shared/hooks/createHooksInternal.tsx",
94
- "/src/server/ssgProxy.ts"
95
- ],
96
- "percent": 5.5,
97
- "reduction": 40.27
98
- },
99
- {
100
- "id": "/src/createTRPCReact.tsx",
101
- "size": 875,
102
- "origSize": 13699,
103
- "renderedExports": [
104
- "createHooksInternal",
105
- "createTRPCReact"
106
- ],
107
- "removedExports": [],
108
- "dependents": [
109
- "/src/index.ts"
110
- ],
111
- "percent": 1.92,
112
- "reduction": 93.61
113
- },
114
- {
115
- "id": "/src/internals/trpcResult.ts",
116
- "size": 865,
117
- "origSize": 1235,
118
- "renderedExports": [
119
- "createTRPCOptionsResult",
120
- "useHookResult",
121
- "buildQueryFromAsyncIterable"
122
- ],
123
- "removedExports": [],
124
- "dependents": [
125
- "/src/shared/hooks/createHooksInternal.tsx",
126
- "/src/utils/createUtilityFunctions.ts"
127
- ],
128
- "percent": 1.9,
129
- "reduction": 29.96
130
- },
131
- {
132
- "id": "/src/shared/proxy/decorationProxy.ts",
133
- "size": 780,
134
- "origSize": 1029,
135
- "renderedExports": [
136
- "createReactDecoration"
137
- ],
138
- "removedExports": [],
139
- "dependents": [
140
- "/src/shared/index.ts"
141
- ],
142
- "percent": 1.71,
143
- "reduction": 24.2
144
- },
145
- {
146
- "id": "/src/shared/proxy/useQueriesProxy.ts",
147
- "size": 697,
148
- "origSize": 3419,
149
- "renderedExports": [
150
- "createUseQueries"
151
- ],
152
- "removedExports": [],
153
- "dependents": [
154
- "/src/shared/index.ts",
155
- "/src/shared/hooks/createHooksInternal.tsx"
156
- ],
157
- "percent": 1.53,
158
- "reduction": 79.61
159
- },
160
- {
161
- "id": "/src/internals/getClientArgs.ts",
162
- "size": 473,
163
- "origSize": 572,
164
- "renderedExports": [
165
- "getClientArgs"
166
- ],
167
- "removedExports": [],
168
- "dependents": [
169
- "/src/shared/index.ts",
170
- "/src/shared/hooks/createHooksInternal.tsx",
171
- "/src/utils/createUtilityFunctions.ts"
172
- ],
173
- "percent": 1.04,
174
- "reduction": 17.31
175
- },
176
- {
177
- "id": "/src/createTRPCQueryUtils.tsx",
178
- "size": 162,
179
- "origSize": 485,
180
- "renderedExports": [
181
- "createTRPCQueryUtils"
182
- ],
183
- "removedExports": [],
184
- "dependents": [
185
- "/src/index.ts"
186
- ],
187
- "percent": 0.36,
188
- "reduction": 66.6
189
- },
190
- {
191
- "id": "/src/internals/context.tsx",
192
- "size": 154,
193
- "origSize": 9191,
194
- "renderedExports": [
195
- "contextProps",
196
- "TRPCContext"
197
- ],
198
- "removedExports": [],
199
- "dependents": [
200
- "/src/shared/index.ts",
201
- "/src/shared/index.ts",
202
- "/src/shared/proxy/utilsProxy.ts",
203
- "/src/shared/hooks/createHooksInternal.tsx"
204
- ],
205
- "percent": 0.34,
206
- "reduction": 98.32
207
- },
208
- {
209
- "id": "/src/shared/queryClient.ts",
210
- "size": 129,
211
- "origSize": 514,
212
- "renderedExports": [
213
- "getQueryClient"
214
- ],
215
- "removedExports": [],
216
- "dependents": [
217
- "/src/shared/index.ts"
218
- ],
219
- "percent": 0.28,
220
- "reduction": 74.9
221
- },
222
- {
223
- "id": "/src/index.ts",
224
- "size": 0,
225
- "origSize": 362,
226
- "renderedExports": [],
227
- "removedExports": [],
228
- "dependents": [],
229
- "percent": 0,
230
- "reduction": 100
231
- },
232
- {
233
- "id": "/src/shared/index.ts",
234
- "size": 0,
235
- "origSize": 706,
236
- "renderedExports": [],
237
- "removedExports": [],
238
- "dependents": [
239
- "/src/createTRPCReact.tsx",
240
- "/src/createTRPCQueryUtils.tsx",
241
- "/src/server/ssgProxy.ts"
242
- ],
243
- "percent": 0,
244
- "reduction": 100
245
- },
246
- {
247
- "id": "/src/server/index.ts",
248
- "size": 0,
249
- "origSize": 54,
250
- "renderedExports": [],
251
- "removedExports": [],
252
- "dependents": [],
253
- "percent": 0,
254
- "reduction": 100
255
- }
256
- ],
257
- "moduleCount": 17
258
- }