@trpc/server 11.0.0-rc.329 → 11.0.0-rc.332

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 (57) hide show
  1. package/dist/adapters/aws-lambda/index.js +0 -1
  2. package/dist/adapters/aws-lambda/index.mjs +0 -1
  3. package/dist/adapters/aws-lambda/utils.js +0 -1
  4. package/dist/adapters/aws-lambda/utils.mjs +0 -1
  5. package/dist/adapters/fastify/fastifyRequestHandler.js +0 -1
  6. package/dist/adapters/fastify/fastifyRequestHandler.mjs +0 -1
  7. package/dist/adapters/fetch/fetchRequestHandler.js +0 -1
  8. package/dist/adapters/fetch/fetchRequestHandler.mjs +0 -1
  9. package/dist/adapters/next-app-dir/nextAppDirCaller.js +0 -1
  10. package/dist/adapters/next-app-dir/nextAppDirCaller.mjs +0 -1
  11. package/dist/adapters/next-app-dir/notFound.js +0 -1
  12. package/dist/adapters/next-app-dir/notFound.mjs +0 -1
  13. package/dist/adapters/next-app-dir/redirect.js +0 -1
  14. package/dist/adapters/next-app-dir/redirect.mjs +0 -1
  15. package/dist/adapters/next.js +0 -1
  16. package/dist/adapters/next.mjs +0 -1
  17. package/dist/adapters/node-http/content-type/json/getPostBody.js +0 -1
  18. package/dist/adapters/node-http/content-type/json/getPostBody.mjs +0 -1
  19. package/dist/adapters/node-http/content-type/json/index.js +0 -1
  20. package/dist/adapters/node-http/content-type/json/index.mjs +0 -1
  21. package/dist/adapters/node-http/nodeHTTPRequestHandler.js +0 -1
  22. package/dist/adapters/node-http/nodeHTTPRequestHandler.mjs +0 -1
  23. package/dist/adapters/standalone.js +0 -1
  24. package/dist/adapters/standalone.mjs +0 -1
  25. package/dist/adapters/ws.js +0 -1
  26. package/dist/adapters/ws.mjs +0 -1
  27. package/dist/bundle-analysis.json +60 -63
  28. package/dist/http.js +0 -1
  29. package/dist/http.mjs +0 -1
  30. package/dist/index.js +0 -1
  31. package/dist/index.mjs +0 -1
  32. package/dist/rpc.js +0 -1
  33. package/dist/rpc.mjs +0 -1
  34. package/dist/shared.js +0 -1
  35. package/dist/shared.mjs +0 -1
  36. package/dist/unstable-core-do-not-import/error/getErrorShape.js +0 -1
  37. package/dist/unstable-core-do-not-import/error/getErrorShape.mjs +0 -1
  38. package/dist/unstable-core-do-not-import/http/getHTTPStatusCode.js +0 -1
  39. package/dist/unstable-core-do-not-import/http/getHTTPStatusCode.mjs +0 -1
  40. package/dist/unstable-core-do-not-import/initTRPC.d.ts.map +1 -1
  41. package/dist/unstable-core-do-not-import/initTRPC.js +1 -2
  42. package/dist/unstable-core-do-not-import/initTRPC.mjs +1 -2
  43. package/dist/unstable-core-do-not-import/procedure.d.ts +4 -0
  44. package/dist/unstable-core-do-not-import/procedure.d.ts.map +1 -1
  45. package/dist/unstable-core-do-not-import/procedureBuilder.js +1 -1
  46. package/dist/unstable-core-do-not-import/procedureBuilder.mjs +2 -2
  47. package/dist/unstable-core-do-not-import/utils.d.ts +0 -5
  48. package/dist/unstable-core-do-not-import/utils.d.ts.map +1 -1
  49. package/dist/unstable-core-do-not-import/utils.js +0 -9
  50. package/dist/unstable-core-do-not-import/utils.mjs +1 -9
  51. package/dist/unstable-core-do-not-import.js +0 -1
  52. package/dist/unstable-core-do-not-import.mjs +1 -1
  53. package/package.json +2 -2
  54. package/src/unstable-core-do-not-import/initTRPC.ts +1 -2
  55. package/src/unstable-core-do-not-import/procedure.ts +4 -0
  56. package/src/unstable-core-do-not-import/procedureBuilder.ts +2 -2
  57. package/src/unstable-core-do-not-import/utils.ts +0 -12
@@ -1,6 +1,5 @@
1
1
  'use strict';
2
2
 
3
- require('../../unstable-core-do-not-import/utils.js');
4
3
  var TRPCError = require('../../unstable-core-do-not-import/error/TRPCError.js');
5
4
  var resolveHTTPResponse = require('../../unstable-core-do-not-import/http/resolveHTTPResponse.js');
6
5
  require('../../unstable-core-do-not-import/rootConfig.js');
@@ -1,4 +1,3 @@
1
- import '../../unstable-core-do-not-import/utils.mjs';
2
1
  import { TRPCError } from '../../unstable-core-do-not-import/error/TRPCError.mjs';
3
2
  import { resolveHTTPResponse } from '../../unstable-core-do-not-import/http/resolveHTTPResponse.mjs';
4
3
  import '../../unstable-core-do-not-import/rootConfig.mjs';
@@ -1,6 +1,5 @@
1
1
  'use strict';
2
2
 
3
- require('../../unstable-core-do-not-import/utils.js');
4
3
  var TRPCError = require('../../unstable-core-do-not-import/error/TRPCError.js');
5
4
  require('../../unstable-core-do-not-import/rootConfig.js');
6
5
 
@@ -1,4 +1,3 @@
1
- import '../../unstable-core-do-not-import/utils.mjs';
2
1
  import { TRPCError } from '../../unstable-core-do-not-import/error/TRPCError.mjs';
3
2
  import '../../unstable-core-do-not-import/rootConfig.mjs';
4
3
 
@@ -1,7 +1,6 @@
1
1
  'use strict';
2
2
 
3
3
  var node_stream = require('node:stream');
4
- require('../../unstable-core-do-not-import/utils.js');
5
4
  var resolveHTTPResponse = require('../../unstable-core-do-not-import/http/resolveHTTPResponse.js');
6
5
  var batchStreamFormatter = require('../../unstable-core-do-not-import/http/batchStreamFormatter.js');
7
6
  require('../../unstable-core-do-not-import/rootConfig.js');
@@ -1,5 +1,4 @@
1
1
  import { Readable } from 'node:stream';
2
- import '../../unstable-core-do-not-import/utils.mjs';
3
2
  import { resolveHTTPResponse } from '../../unstable-core-do-not-import/http/resolveHTTPResponse.mjs';
4
3
  import { getBatchStreamFormatter } from '../../unstable-core-do-not-import/http/batchStreamFormatter.mjs';
5
4
  import '../../unstable-core-do-not-import/rootConfig.mjs';
@@ -1,6 +1,5 @@
1
1
  'use strict';
2
2
 
3
- require('../../unstable-core-do-not-import/utils.js');
4
3
  var resolveHTTPResponse = require('../../unstable-core-do-not-import/http/resolveHTTPResponse.js');
5
4
  var batchStreamFormatter = require('../../unstable-core-do-not-import/http/batchStreamFormatter.js');
6
5
  var toURL = require('../../unstable-core-do-not-import/http/toURL.js');
@@ -1,4 +1,3 @@
1
- import '../../unstable-core-do-not-import/utils.mjs';
2
1
  import { resolveHTTPResponse } from '../../unstable-core-do-not-import/http/resolveHTTPResponse.mjs';
3
2
  import { getBatchStreamFormatter } from '../../unstable-core-do-not-import/http/batchStreamFormatter.mjs';
4
3
  import { toURL } from '../../unstable-core-do-not-import/http/toURL.mjs';
@@ -1,6 +1,5 @@
1
1
  'use strict';
2
2
 
3
- require('../../unstable-core-do-not-import/utils.js');
4
3
  var TRPCError = require('../../unstable-core-do-not-import/error/TRPCError.js');
5
4
  require('../../unstable-core-do-not-import/rootConfig.js');
6
5
  var formDataToObject = require('./formDataToObject.js');
@@ -1,4 +1,3 @@
1
- import '../../unstable-core-do-not-import/utils.mjs';
2
1
  import { TRPCError, getTRPCErrorFromUnknown } from '../../unstable-core-do-not-import/error/TRPCError.mjs';
3
2
  import '../../unstable-core-do-not-import/rootConfig.mjs';
4
3
  import { formDataToObject } from './formDataToObject.mjs';
@@ -1,6 +1,5 @@
1
1
  'use strict';
2
2
 
3
- require('../../unstable-core-do-not-import/utils.js');
4
3
  var TRPCError = require('../../unstable-core-do-not-import/error/TRPCError.js');
5
4
  require('../../unstable-core-do-not-import/rootConfig.js');
6
5
 
@@ -1,4 +1,3 @@
1
- import '../../unstable-core-do-not-import/utils.mjs';
2
1
  import { TRPCError } from '../../unstable-core-do-not-import/error/TRPCError.mjs';
3
2
  import '../../unstable-core-do-not-import/rootConfig.mjs';
4
3
 
@@ -1,6 +1,5 @@
1
1
  'use strict';
2
2
 
3
- require('../../unstable-core-do-not-import/utils.js');
4
3
  var TRPCError = require('../../unstable-core-do-not-import/error/TRPCError.js');
5
4
  require('../../unstable-core-do-not-import/rootConfig.js');
6
5
 
@@ -1,4 +1,3 @@
1
- import '../../unstable-core-do-not-import/utils.mjs';
2
1
  import { TRPCError } from '../../unstable-core-do-not-import/error/TRPCError.mjs';
3
2
  import '../../unstable-core-do-not-import/rootConfig.mjs';
4
3
 
@@ -2,7 +2,6 @@
2
2
 
3
3
  var getErrorShape = require('../unstable-core-do-not-import/error/getErrorShape.js');
4
4
  var TRPCError = require('../unstable-core-do-not-import/error/TRPCError.js');
5
- require('../unstable-core-do-not-import/utils.js');
6
5
  require('../unstable-core-do-not-import/rootConfig.js');
7
6
  var nodeHTTPRequestHandler = require('./node-http/nodeHTTPRequestHandler.js');
8
7
 
@@ -1,6 +1,5 @@
1
1
  import { getErrorShape } from '../unstable-core-do-not-import/error/getErrorShape.mjs';
2
2
  import { TRPCError } from '../unstable-core-do-not-import/error/TRPCError.mjs';
3
- import '../unstable-core-do-not-import/utils.mjs';
4
3
  import '../unstable-core-do-not-import/rootConfig.mjs';
5
4
  import { nodeHTTPRequestHandler } from './node-http/nodeHTTPRequestHandler.mjs';
6
5
 
@@ -1,6 +1,5 @@
1
1
  'use strict';
2
2
 
3
- require('../../../../unstable-core-do-not-import/utils.js');
4
3
  var TRPCError = require('../../../../unstable-core-do-not-import/error/TRPCError.js');
5
4
  require('../../../../unstable-core-do-not-import/rootConfig.js');
6
5
 
@@ -1,4 +1,3 @@
1
- import '../../../../unstable-core-do-not-import/utils.mjs';
2
1
  import { TRPCError } from '../../../../unstable-core-do-not-import/error/TRPCError.mjs';
3
2
  import '../../../../unstable-core-do-not-import/rootConfig.mjs';
4
3
 
@@ -1,6 +1,5 @@
1
1
  'use strict';
2
2
 
3
- require('../../../../unstable-core-do-not-import/utils.js');
4
3
  var contentType$1 = require('../../../../unstable-core-do-not-import/http/contentType.js');
5
4
  require('../../../../unstable-core-do-not-import/rootConfig.js');
6
5
  var contentType = require('../../internals/contentType.js');
@@ -1,4 +1,3 @@
1
- import '../../../../unstable-core-do-not-import/utils.mjs';
2
1
  import { getJsonContentTypeInputs } from '../../../../unstable-core-do-not-import/http/contentType.mjs';
3
2
  import '../../../../unstable-core-do-not-import/rootConfig.mjs';
4
3
  import { createNodeHTTPContentTypeHandler } from '../../internals/contentType.mjs';
@@ -1,6 +1,5 @@
1
1
  'use strict';
2
2
 
3
- require('../../unstable-core-do-not-import/utils.js');
4
3
  var resolveHTTPResponse = require('../../unstable-core-do-not-import/http/resolveHTTPResponse.js');
5
4
  var batchStreamFormatter = require('../../unstable-core-do-not-import/http/batchStreamFormatter.js');
6
5
  require('../../unstable-core-do-not-import/rootConfig.js');
@@ -1,4 +1,3 @@
1
- import '../../unstable-core-do-not-import/utils.mjs';
2
1
  import { resolveHTTPResponse } from '../../unstable-core-do-not-import/http/resolveHTTPResponse.mjs';
3
2
  import { getBatchStreamFormatter } from '../../unstable-core-do-not-import/http/batchStreamFormatter.mjs';
4
3
  import '../../unstable-core-do-not-import/rootConfig.mjs';
@@ -1,7 +1,6 @@
1
1
  'use strict';
2
2
 
3
3
  var http = require('node:http');
4
- require('../unstable-core-do-not-import/utils.js');
5
4
  var toURL = require('../unstable-core-do-not-import/http/toURL.js');
6
5
  require('../unstable-core-do-not-import/rootConfig.js');
7
6
  var nodeHTTPRequestHandler = require('./node-http/nodeHTTPRequestHandler.js');
@@ -1,5 +1,4 @@
1
1
  import http from 'node:http';
2
- import '../unstable-core-do-not-import/utils.mjs';
3
2
  import { toURL } from '../unstable-core-do-not-import/http/toURL.mjs';
4
3
  import '../unstable-core-do-not-import/rootConfig.mjs';
5
4
  import { nodeHTTPRequestHandler } from './node-http/nodeHTTPRequestHandler.mjs';
@@ -5,7 +5,6 @@ var TRPCError = require('../unstable-core-do-not-import/error/TRPCError.js');
5
5
  var parseTRPCMessage = require('../unstable-core-do-not-import/rpc/parseTRPCMessage.js');
6
6
  var router = require('../unstable-core-do-not-import/router.js');
7
7
  var transformer = require('../unstable-core-do-not-import/transformer.js');
8
- require('../unstable-core-do-not-import/utils.js');
9
8
  require('../unstable-core-do-not-import/rootConfig.js');
10
9
  var observable = require('../observable/observable.js');
11
10
 
@@ -3,7 +3,6 @@ import { TRPCError, getTRPCErrorFromUnknown } from '../unstable-core-do-not-impo
3
3
  import { parseTRPCMessage } from '../unstable-core-do-not-import/rpc/parseTRPCMessage.mjs';
4
4
  import { callProcedure } from '../unstable-core-do-not-import/router.mjs';
5
5
  import { transformTRPCResponse } from '../unstable-core-do-not-import/transformer.mjs';
6
- import '../unstable-core-do-not-import/utils.mjs';
7
6
  import '../unstable-core-do-not-import/rootConfig.mjs';
8
7
  import { isObservable } from '../observable/observable.mjs';
9
8
 
@@ -1,7 +1,7 @@
1
1
  {
2
- "bundleSize": 98628,
3
- "bundleOrigSize": 157786,
4
- "bundleReduction": 37.49,
2
+ "bundleSize": 98388,
3
+ "bundleOrigSize": 157552,
4
+ "bundleReduction": 37.55,
5
5
  "modules": [
6
6
  {
7
7
  "id": "/src/adapters/ws.ts",
@@ -15,7 +15,7 @@
15
15
  "dependents": [
16
16
  "/src/adapters/fastify/fastifyTRPCPlugin.ts"
17
17
  ],
18
- "percent": 10.31,
18
+ "percent": 10.34,
19
19
  "reduction": 0
20
20
  },
21
21
  {
@@ -27,13 +27,13 @@
27
27
  ],
28
28
  "removedExports": [],
29
29
  "dependents": [],
30
- "percent": 9.61,
30
+ "percent": 9.63,
31
31
  "reduction": 20.86
32
32
  },
33
33
  {
34
34
  "id": "/src/unstable-core-do-not-import/procedureBuilder.ts",
35
- "size": 6399,
36
- "origSize": 15701,
35
+ "size": 6386,
36
+ "origSize": 15688,
37
37
  "renderedExports": [
38
38
  "unsetMarker",
39
39
  "createBuilder"
@@ -44,7 +44,7 @@
44
44
  "/src/unstable-core-do-not-import/initTRPC.ts"
45
45
  ],
46
46
  "percent": 6.49,
47
- "reduction": 59.24
47
+ "reduction": 59.29
48
48
  },
49
49
  {
50
50
  "id": "/src/unstable-core-do-not-import/router.ts",
@@ -62,7 +62,7 @@
62
62
  "/src/unstable-core-do-not-import/http/resolveHTTPResponse.ts",
63
63
  "/src/unstable-core-do-not-import/initTRPC.ts"
64
64
  ],
65
- "percent": 5.91,
65
+ "percent": 5.93,
66
66
  "reduction": 41.71
67
67
  },
68
68
  {
@@ -78,7 +78,7 @@
78
78
  "dependents": [
79
79
  "/src/adapters/node-http/content-type/form-data/index.ts"
80
80
  ],
81
- "percent": 5.05,
81
+ "percent": 5.06,
82
82
  "reduction": 38
83
83
  },
84
84
  {
@@ -92,7 +92,7 @@
92
92
  ],
93
93
  "removedExports": [],
94
94
  "dependents": [],
95
- "percent": 4.48,
95
+ "percent": 4.49,
96
96
  "reduction": 32.71
97
97
  },
98
98
  {
@@ -106,7 +106,7 @@
106
106
  "dependents": [
107
107
  "/src/adapters/node-http/index.ts"
108
108
  ],
109
- "percent": 3.99,
109
+ "percent": 4,
110
110
  "reduction": 13.56
111
111
  },
112
112
  {
@@ -139,7 +139,7 @@
139
139
  "dependents": [
140
140
  "/src/adapters/aws-lambda/index.ts"
141
141
  ],
142
- "percent": 3.35,
142
+ "percent": 3.36,
143
143
  "reduction": 34.98
144
144
  },
145
145
  {
@@ -156,7 +156,7 @@
156
156
  "/src/observable/index.ts",
157
157
  "/src/observable/operators.ts"
158
158
  ],
159
- "percent": 3.17,
159
+ "percent": 3.18,
160
160
  "reduction": 0.67
161
161
  },
162
162
  {
@@ -170,7 +170,7 @@
170
170
  "dependents": [
171
171
  "/src/adapters/next-app-dir.ts"
172
172
  ],
173
- "percent": 3.09,
173
+ "percent": 3.1,
174
174
  "reduction": 21.85
175
175
  },
176
176
  {
@@ -186,7 +186,7 @@
186
186
  "dependents": [
187
187
  "/src/observable/index.ts"
188
188
  ],
189
- "percent": 2.79,
189
+ "percent": 2.8,
190
190
  "reduction": 0
191
191
  },
192
192
  {
@@ -206,13 +206,13 @@
206
206
  "/src/unstable-core-do-not-import/router.ts",
207
207
  "/src/unstable-core-do-not-import/initTRPC.ts"
208
208
  ],
209
- "percent": 2.78,
209
+ "percent": 2.79,
210
210
  "reduction": 45.94
211
211
  },
212
212
  {
213
213
  "id": "/src/unstable-core-do-not-import/initTRPC.ts",
214
- "size": 2665,
215
- "origSize": 4540,
214
+ "size": 2652,
215
+ "origSize": 4501,
216
216
  "renderedExports": [
217
217
  "initTRPC"
218
218
  ],
@@ -221,7 +221,7 @@
221
221
  "/src/unstable-core-do-not-import.ts"
222
222
  ],
223
223
  "percent": 2.7,
224
- "reduction": 41.3
224
+ "reduction": 41.08
225
225
  },
226
226
  {
227
227
  "id": "/src/unstable-core-do-not-import/middleware.ts",
@@ -240,7 +240,7 @@
240
240
  "/src/unstable-core-do-not-import/initTRPC.ts",
241
241
  "/src/unstable-core-do-not-import/procedureBuilder.ts"
242
242
  ],
243
- "percent": 2.66,
243
+ "percent": 2.67,
244
244
  "reduction": 55.5
245
245
  },
246
246
  {
@@ -255,7 +255,7 @@
255
255
  "/src/adapters/fastify/index.ts",
256
256
  "/src/adapters/fastify/fastifyTRPCPlugin.ts"
257
257
  ],
258
- "percent": 2.51,
258
+ "percent": 2.52,
259
259
  "reduction": 36.53
260
260
  },
261
261
  {
@@ -267,7 +267,7 @@
267
267
  ],
268
268
  "removedExports": [],
269
269
  "dependents": [],
270
- "percent": 2.48,
270
+ "percent": 2.49,
271
271
  "reduction": 32.42
272
272
  },
273
273
  {
@@ -302,7 +302,7 @@
302
302
  "dependents": [
303
303
  "/src/unstable-core-do-not-import/http/resolveHTTPResponse.ts"
304
304
  ],
305
- "percent": 1.66,
305
+ "percent": 1.67,
306
306
  "reduction": 34.79
307
307
  },
308
308
  {
@@ -314,7 +314,7 @@
314
314
  ],
315
315
  "removedExports": [],
316
316
  "dependents": [],
317
- "percent": 1.62,
317
+ "percent": 1.63,
318
318
  "reduction": 29.12
319
319
  },
320
320
  {
@@ -328,7 +328,7 @@
328
328
  "dependents": [
329
329
  "/src/adapters/node-http/content-type/json/index.ts"
330
330
  ],
331
- "percent": 1.61,
331
+ "percent": 1.62,
332
332
  "reduction": 0.19
333
333
  },
334
334
  {
@@ -340,7 +340,7 @@
340
340
  ],
341
341
  "removedExports": [],
342
342
  "dependents": [],
343
- "percent": 1.6,
343
+ "percent": 1.61,
344
344
  "reduction": 21.04
345
345
  },
346
346
  {
@@ -367,7 +367,6 @@
367
367
  "removedExports": [],
368
368
  "dependents": [
369
369
  "/src/unstable-core-do-not-import.ts",
370
- "/src/unstable-core-do-not-import/utils.ts",
371
370
  "/src/unstable-core-do-not-import/router.ts"
372
371
  ],
373
372
  "percent": 1.53,
@@ -384,7 +383,7 @@
384
383
  "dependents": [
385
384
  "/src/adapters/fastify/index.ts"
386
385
  ],
387
- "percent": 1.5,
386
+ "percent": 1.51,
388
387
  "reduction": 34.44
389
388
  },
390
389
  {
@@ -398,7 +397,7 @@
398
397
  "dependents": [
399
398
  "/src/adapters/node-http/content-type/form-data/fileUploadHandler.ts"
400
399
  ],
401
- "percent": 1.41,
400
+ "percent": 1.42,
402
401
  "reduction": 0
403
402
  },
404
403
  {
@@ -414,34 +413,9 @@
414
413
  "/src/unstable-core-do-not-import/http/resolveHTTPResponse.ts",
415
414
  "/src/unstable-core-do-not-import/error/getErrorShape.ts"
416
415
  ],
417
- "percent": 1.28,
416
+ "percent": 1.29,
418
417
  "reduction": 22.76
419
418
  },
420
- {
421
- "id": "/src/unstable-core-do-not-import/utils.ts",
422
- "size": 1094,
423
- "origSize": 1425,
424
- "renderedExports": [
425
- "mergeWithoutOverrides",
426
- "isObject",
427
- "isFunction",
428
- "omitPrototype",
429
- "$typesProxy"
430
- ],
431
- "removedExports": [],
432
- "dependents": [
433
- "/src/unstable-core-do-not-import.ts",
434
- "/src/unstable-core-do-not-import/error/TRPCError.ts",
435
- "/src/unstable-core-do-not-import/router.ts",
436
- "/src/unstable-core-do-not-import/transformer.ts",
437
- "/src/unstable-core-do-not-import/initTRPC.ts",
438
- "/src/unstable-core-do-not-import/middleware.ts",
439
- "/src/unstable-core-do-not-import/rpc/parseTRPCMessage.ts",
440
- "/src/unstable-core-do-not-import/procedureBuilder.ts"
441
- ],
442
- "percent": 1.11,
443
- "reduction": 23.23
444
- },
445
419
  {
446
420
  "id": "/src/unstable-core-do-not-import/parser.ts",
447
421
  "size": 992,
@@ -474,6 +448,29 @@
474
448
  "percent": 1,
475
449
  "reduction": 13.65
476
450
  },
451
+ {
452
+ "id": "/src/unstable-core-do-not-import/utils.ts",
453
+ "size": 880,
454
+ "origSize": 1151,
455
+ "renderedExports": [
456
+ "mergeWithoutOverrides",
457
+ "isObject",
458
+ "isFunction",
459
+ "omitPrototype"
460
+ ],
461
+ "removedExports": [],
462
+ "dependents": [
463
+ "/src/unstable-core-do-not-import.ts",
464
+ "/src/unstable-core-do-not-import/error/TRPCError.ts",
465
+ "/src/unstable-core-do-not-import/router.ts",
466
+ "/src/unstable-core-do-not-import/transformer.ts",
467
+ "/src/unstable-core-do-not-import/middleware.ts",
468
+ "/src/unstable-core-do-not-import/rpc/parseTRPCMessage.ts",
469
+ "/src/unstable-core-do-not-import/procedureBuilder.ts"
470
+ ],
471
+ "percent": 0.89,
472
+ "reduction": 23.54
473
+ },
477
474
  {
478
475
  "id": "/src/adapters/next-app-dir/formDataToObject.ts",
479
476
  "size": 818,
@@ -546,7 +543,7 @@
546
543
  "/src/unstable-core-do-not-import.ts",
547
544
  "/src/unstable-core-do-not-import/http/resolveHTTPResponse.ts"
548
545
  ],
549
- "percent": 0.63,
546
+ "percent": 0.64,
550
547
  "reduction": 43.49
551
548
  },
552
549
  {
@@ -675,7 +672,7 @@
675
672
  {
676
673
  "id": "/src/unstable-core-do-not-import/procedure.ts",
677
674
  "size": 75,
678
- "origSize": 2301,
675
+ "origSize": 2393,
679
676
  "renderedExports": [
680
677
  "procedureTypes"
681
678
  ],
@@ -685,7 +682,7 @@
685
682
  "/src/unstable-core-do-not-import/rpc/parseTRPCMessage.ts"
686
683
  ],
687
684
  "percent": 0.08,
688
- "reduction": 96.74
685
+ "reduction": 96.87
689
686
  },
690
687
  {
691
688
  "id": "/src/unstable-core-do-not-import/error/formatter.ts",
@@ -724,9 +721,9 @@
724
721
  "reduction": 100
725
722
  },
726
723
  {
727
- "id": "/src/shared.ts",
724
+ "id": "/src/rpc.ts",
728
725
  "size": 0,
729
- "origSize": 653,
726
+ "origSize": 36,
730
727
  "renderedExports": [],
731
728
  "removedExports": [],
732
729
  "dependents": [],
@@ -734,9 +731,9 @@
734
731
  "reduction": 100
735
732
  },
736
733
  {
737
- "id": "/src/rpc.ts",
734
+ "id": "/src/shared.ts",
738
735
  "size": 0,
739
- "origSize": 36,
736
+ "origSize": 653,
740
737
  "renderedExports": [],
741
738
  "removedExports": [],
742
739
  "dependents": [],
package/dist/http.js CHANGED
@@ -1,7 +1,6 @@
1
1
  'use strict';
2
2
 
3
3
  var getHTTPStatusCode = require('./unstable-core-do-not-import/http/getHTTPStatusCode.js');
4
- require('./unstable-core-do-not-import/utils.js');
5
4
  var resolveHTTPResponse = require('./unstable-core-do-not-import/http/resolveHTTPResponse.js');
6
5
  var batchStreamFormatter = require('./unstable-core-do-not-import/http/batchStreamFormatter.js');
7
6
  var contentType = require('./unstable-core-do-not-import/http/contentType.js');
package/dist/http.mjs CHANGED
@@ -1,5 +1,4 @@
1
1
  export { getHTTPStatusCode, getHTTPStatusCodeFromError } from './unstable-core-do-not-import/http/getHTTPStatusCode.mjs';
2
- import './unstable-core-do-not-import/utils.mjs';
3
2
  export { resolveHTTPResponse } from './unstable-core-do-not-import/http/resolveHTTPResponse.mjs';
4
3
  export { getBatchStreamFormatter } from './unstable-core-do-not-import/http/batchStreamFormatter.mjs';
5
4
  export { getJsonContentTypeInputs } from './unstable-core-do-not-import/http/contentType.mjs';
package/dist/index.js CHANGED
@@ -3,7 +3,6 @@
3
3
  var createProxy = require('./unstable-core-do-not-import/createProxy.js');
4
4
  var getErrorShape = require('./unstable-core-do-not-import/error/getErrorShape.js');
5
5
  var TRPCError = require('./unstable-core-do-not-import/error/TRPCError.js');
6
- require('./unstable-core-do-not-import/utils.js');
7
6
  var router = require('./unstable-core-do-not-import/router.js');
8
7
  var transformer = require('./unstable-core-do-not-import/transformer.js');
9
8
  var initTRPC = require('./unstable-core-do-not-import/initTRPC.js');
package/dist/index.mjs CHANGED
@@ -1,7 +1,6 @@
1
1
  export { createFlatProxy as createTRPCFlatProxy } from './unstable-core-do-not-import/createProxy.mjs';
2
2
  export { getErrorShape } from './unstable-core-do-not-import/error/getErrorShape.mjs';
3
3
  export { TRPCError, getTRPCErrorFromUnknown } from './unstable-core-do-not-import/error/TRPCError.mjs';
4
- import './unstable-core-do-not-import/utils.mjs';
5
4
  export { callProcedure, callProcedure as callTRPCProcedure } from './unstable-core-do-not-import/router.mjs';
6
5
  export { transformTRPCResponse } from './unstable-core-do-not-import/transformer.mjs';
7
6
  export { initTRPC } from './unstable-core-do-not-import/initTRPC.mjs';
package/dist/rpc.js CHANGED
@@ -2,7 +2,6 @@
2
2
 
3
3
  var codes = require('./unstable-core-do-not-import/rpc/codes.js');
4
4
  var parseTRPCMessage = require('./unstable-core-do-not-import/rpc/parseTRPCMessage.js');
5
- require('./unstable-core-do-not-import/utils.js');
6
5
  require('./unstable-core-do-not-import/rootConfig.js');
7
6
 
8
7
 
package/dist/rpc.mjs CHANGED
@@ -1,4 +1,3 @@
1
1
  export { TRPC_ERROR_CODES_BY_KEY, TRPC_ERROR_CODES_BY_NUMBER } from './unstable-core-do-not-import/rpc/codes.mjs';
2
2
  export { parseTRPCMessage } from './unstable-core-do-not-import/rpc/parseTRPCMessage.mjs';
3
- import './unstable-core-do-not-import/utils.mjs';
4
3
  import './unstable-core-do-not-import/rootConfig.mjs';
package/dist/shared.js CHANGED
@@ -2,7 +2,6 @@
2
2
 
3
3
  var createProxy = require('./unstable-core-do-not-import/createProxy.js');
4
4
  var getErrorShape = require('./unstable-core-do-not-import/error/getErrorShape.js');
5
- require('./unstable-core-do-not-import/utils.js');
6
5
  require('./unstable-core-do-not-import/rootConfig.js');
7
6
 
8
7
 
package/dist/shared.mjs CHANGED
@@ -1,4 +1,3 @@
1
1
  export { createFlatProxy } from './unstable-core-do-not-import/createProxy.mjs';
2
2
  export { getErrorShape } from './unstable-core-do-not-import/error/getErrorShape.mjs';
3
- import './unstable-core-do-not-import/utils.mjs';
4
3
  import './unstable-core-do-not-import/rootConfig.mjs';
@@ -2,7 +2,6 @@
2
2
 
3
3
  var getHTTPStatusCode = require('../http/getHTTPStatusCode.js');
4
4
  var codes = require('../rpc/codes.js');
5
- require('../utils.js');
6
5
 
7
6
  /**
8
7
  * @internal
@@ -1,6 +1,5 @@
1
1
  import { getHTTPStatusCodeFromError } from '../http/getHTTPStatusCode.mjs';
2
2
  import { TRPC_ERROR_CODES_BY_KEY } from '../rpc/codes.mjs';
3
- import '../utils.mjs';
4
3
 
5
4
  /**
6
5
  * @internal
@@ -1,7 +1,6 @@
1
1
  'use strict';
2
2
 
3
3
  var codes = require('../rpc/codes.js');
4
- require('../utils.js');
5
4
 
6
5
  const JSONRPC2_TO_HTTP_CODE = {
7
6
  PARSE_ERROR: 400,
@@ -1,5 +1,4 @@
1
1
  import { TRPC_ERROR_CODES_BY_NUMBER } from '../rpc/codes.mjs';
2
- import '../utils.mjs';
3
2
 
4
3
  const JSONRPC2_TO_HTTP_CODE = {
5
4
  PARSE_ERROR: 400,
@@ -1 +1 @@
1
- {"version":3,"file":"initTRPC.d.ts","sourceRoot":"","sources":["../../src/unstable-core-do-not-import/initTRPC.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,KAAK,iBAAiB,EACtB,KAAK,cAAc,EACpB,MAAM,mBAAmB,CAAC;AAI3B,OAAO,EAAmB,KAAK,UAAU,EAAE,MAAM,cAAc,CAAC;AAChE,OAAO,EAGL,YAAY,EACb,MAAM,UAAU,CAAC;AAClB,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,eAAe,CAAC;AAE5D,OAAO,KAAK,EAAE,MAAM,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAGrD,KAAK,wBAAwB,CAAC,KAAK,IAAI,KAAK,SAAS,cAAc,CACjE,GAAG,EACH,MAAM,MAAM,CACb,GACG,MAAM,GACN,iBAAiB,CAAC;AACtB,UAAU,oBAAoB,CAAC,QAAQ,SAAS,MAAM,EAAE,KAAK,SAAS,MAAM,CAC1E,SAAQ,OAAO,CACb,IAAI,CACF,UAAU,CAAC;IACT,GAAG,EAAE,QAAQ,CAAC;IACd,IAAI,EAAE,KAAK,CAAC;IACZ,UAAU,EAAE,GAAG,CA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AC,gBAAgB,CAAC,GACpD,iBAAiB,GACjB,yBAAyB,QAAQ,CAAC,gBAAgB,CAAC,CAAC;6BAC3C,SAAS,SAAS,QAAQ,CAAC,aAAa,CAAC,GAAG,KAAK,GAAG,IAAI;;;QAoDrE;;;WAGG;;QAEH;;;WAGG;;iBAjEE,QAAQ;kBACP,KAAK;wBACC,SAAS,SAAS,QAAQ,CAAC,gBAAgB,CAAC,GACpD,iBAAiB,GACjB,yBAAyB,QAAQ,CAAC,gBAAgB,CAAC,CAAC;yBAC3C,SAAS,SAAS,QAAQ,CAAC,aAAa,CAAC,GAAG,KAAK,GAAG,IAAI;;iBALhE,QAAQ;kBACP,KAAK;wBACC,SAAS,SAAS,QAAQ,CAAC,gBAAgB,CAAC,GACpD,iBAAiB,GACjB,yBAAyB,QAAQ,CAAC,gBAAgB,CAAC,CAAC;yBAC3C,SAAS,SAAS,QAAQ,CAAC,aAAa,CAAC,GAAG,KAAK,GAAG,IAAI;;;CAgE1E;AAED;;;GAGG;AACH,eAAO,MAAM,QAAQ,6BAAoB,CAAC"}
@@ -6,7 +6,6 @@ var procedureBuilder = require('./procedureBuilder.js');
6
6
  var rootConfig = require('./rootConfig.js');
7
7
  var router = require('./router.js');
8
8
  var transformer = require('./transformer.js');
9
- var utils = require('./utils.js');
10
9
 
11
10
  class TRPCBuilder {
12
11
  /**
@@ -35,7 +34,7 @@ class TRPCBuilder {
35
34
  /**
36
35
  * These are just types, they can't be used at runtime
37
36
  * @internal
38
- */ $types: utils.$typesProxy
37
+ */ $types: null
39
38
  };
40
39
  {
41
40
  // Server check
@@ -4,7 +4,6 @@ import { createBuilder } from './procedureBuilder.mjs';
4
4
  import { isServerDefault } from './rootConfig.mjs';
5
5
  import { createRouterFactory, mergeRouters, createCallerFactory } from './router.mjs';
6
6
  import { getDataTransformer, defaultTransformer } from './transformer.mjs';
7
- import { $typesProxy } from './utils.mjs';
8
7
 
9
8
  class TRPCBuilder {
10
9
  /**
@@ -33,7 +32,7 @@ class TRPCBuilder {
33
32
  /**
34
33
  * These are just types, they can't be used at runtime
35
34
  * @internal
36
- */ $types: $typesProxy
35
+ */ $types: null
37
36
  };
38
37
  {
39
38
  // Server check
@@ -26,6 +26,10 @@ interface BuiltProcedureDef {
26
26
  */
27
27
  export interface Procedure<TType extends ProcedureType, TDef extends BuiltProcedureDef> {
28
28
  _def: {
29
+ /**
30
+ * These are just types, they can't be used at runtime
31
+ * @internal
32
+ */
29
33
  $types: {
30
34
  input: TDef['input'];
31
35
  output: TDef['output'];
@@ -1 +1 @@
1
- {"version":3,"file":"procedure.d.ts","sourceRoot":"","sources":["../../src/unstable-core-do-not-import/procedure.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AACnD,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,oBAAoB,CAAC;AAE/D,eAAO,MAAM,cAAc,gDAAiD,CAAC;AAC7E;;GAEG;AACH,MAAM,MAAM,aAAa,GAAG,CAAC,OAAO,cAAc,CAAC,CAAC,MAAM,CAAC,CAAC;AAE5D,KAAK,aAAa,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;AAE7C;;GAEG;AACH,MAAM,WAAW,gBAAgB;IAC/B;;OAEG;IACH,OAAO,CAAC,EAAE,aAAa,CAAC;IACxB,MAAM,CAAC,EAAE,WAAW,CAAC;CACtB;AAED,UAAU,iBAAiB;IACzB,KAAK,EAAE,OAAO,CAAC;IACf,MAAM,EAAE,OAAO,CAAC;CACjB;AAED;;;GAGG;AACH,MAAM,WAAW,SAAS,CACxB,KAAK,SAAS,aAAa,EAC3B,IAAI,SAAS,iBAAiB;IAE9B,IAAI,EAAE;QACJ,MAAM,EAAE;YACN,KAAK,EAAE,IAAI,CAAC,OAAO,CAAC,CAAC;YACrB,MAAM,EAAE,IAAI,CAAC,QAAQ,CAAC,CAAC;SACxB,CAAC;QACF,SAAS,EAAE,IAAI,CAAC;QAChB,IAAI,EAAE,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AClB,KAAK,CAAC;AACV,MAAM,MAAM,oBAAoB,CAAC,UAAU,IACzC,oBAAoB,CAAC,UAAU,CAAC,CAAC,QAAQ,CAAC,CAAC,QAAQ,CAAC,CAAC;AAEvD;;GAEG;AACH,MAAM,WAAW,mBAAmB,CAAC,QAAQ;IAC3C,KAAK,EAAE,SAAS,CAAC;IACjB,IAAI,EAAE,aAAa,GAAG,SAAS,CAAC;IAChC,IAAI,EAAE,MAAM,GAAG,SAAS,CAAC;IACzB,KAAK,EAAE,OAAO,CAAC;IACf,GAAG,EAAE,QAAQ,GAAG,SAAS,CAAC;CAC3B"}
@@ -117,7 +117,7 @@ function createResolver(_defIn, resolver) {
117
117
  type: _defIn.type,
118
118
  experimental_caller: Boolean(finalBuilder._def.caller),
119
119
  meta: finalBuilder._def.meta,
120
- $types: utils.$typesProxy
120
+ $types: null
121
121
  };
122
122
  const invoke = createProcedureCaller(finalBuilder._def);
123
123
  const callerOverride = finalBuilder._def.caller;
@@ -1,7 +1,7 @@
1
1
  import { TRPCError, getTRPCErrorFromUnknown } from './error/TRPCError.mjs';
2
2
  import { createInputMiddleware, createOutputMiddleware, middlewareMarker } from './middleware.mjs';
3
3
  import { getParseFn } from './parser.mjs';
4
- import { $typesProxy, mergeWithoutOverrides } from './utils.mjs';
4
+ import { mergeWithoutOverrides } from './utils.mjs';
5
5
 
6
6
  /** @internal */ const unsetMarker = Symbol('unsetMarker');
7
7
  function createNewBuilder(def1, def2) {
@@ -115,7 +115,7 @@ function createResolver(_defIn, resolver) {
115
115
  type: _defIn.type,
116
116
  experimental_caller: Boolean(finalBuilder._def.caller),
117
117
  meta: finalBuilder._def.meta,
118
- $types: $typesProxy
118
+ $types: null
119
119
  };
120
120
  const invoke = createProcedureCaller(finalBuilder._def);
121
121
  const callerOverride = finalBuilder._def.caller;
@@ -15,10 +15,5 @@ export declare function isFunction(fn: unknown): fn is AnyFn;
15
15
  * @internal
16
16
  */
17
17
  export declare function omitPrototype<TObj extends Record<string, unknown>>(obj: TObj): TObj;
18
- /**
19
- * Prevents access to `$types` at runtime
20
- * @internal
21
- */
22
- export declare const $typesProxy: any;
23
18
  export {};
24
19
  //# sourceMappingURL=utils.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/unstable-core-do-not-import/utils.ts"],"names":[],"mappings":"AAEA;;;GAGG;AACH,wBAAgB,qBAAqB,CAAC,KAAK,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EACzE,IAAI,EAAE,KAAK,EACX,GAAG,IAAI,EAAE,OAAO,CAAC,KAAK,CAAC,EAAE,GACxB,KAAK,CAYP;AAED;;;GAGG;AACH,wBAAgB,QAAQ,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK,IAAI,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAEzE;AAED,KAAK,KAAK,GAAG,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,OAAO,CAAC;AACzC,wBAAgB,UAAU,CAAC,EAAE,EAAE,OAAO,GAAG,EAAE,IAAI,KAAK,CAEnD;AAED;;;GAGG;AACH,wBAAgB,aAAa,CAAC,IAAI,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAChE,GAAG,EAAE,IAAI,GACR,IAAI,CAEN;AAED;;;GAGG;AACH,eAAO,MAAM,WAAW,KAItB,CAAC"}
1
+ {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/unstable-core-do-not-import/utils.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,wBAAgB,qBAAqB,CAAC,KAAK,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EACzE,IAAI,EAAE,KAAK,EACX,GAAG,IAAI,EAAE,OAAO,CAAC,KAAK,CAAC,EAAE,GACxB,KAAK,CAYP;AAED;;;GAGG;AACH,wBAAgB,QAAQ,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK,IAAI,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAEzE;AAED,KAAK,KAAK,GAAG,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,OAAO,CAAC;AACzC,wBAAgB,UAAU,CAAC,EAAE,EAAE,OAAO,GAAG,EAAE,IAAI,KAAK,CAEnD;AAED;;;GAGG;AACH,wBAAgB,aAAa,CAAC,IAAI,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAChE,GAAG,EAAE,IAAI,GACR,IAAI,CAEN"}
@@ -1,7 +1,5 @@
1
1
  'use strict';
2
2
 
3
- var createProxy = require('./createProxy.js');
4
-
5
3
  /**
6
4
  * Ensures there are no duplicate keys when building a procedure.
7
5
  * @internal
@@ -32,14 +30,7 @@ function isFunction(fn) {
32
30
  */ function omitPrototype(obj) {
33
31
  return Object.assign(Object.create(null), obj);
34
32
  }
35
- /**
36
- * Prevents access to `$types` at runtime
37
- * @internal
38
- */ const $typesProxy = createProxy.createFlatProxy((key)=>{
39
- throw new Error(`Tried to access "$types.${key}" which is not available at runtime`);
40
- });
41
33
 
42
- exports.$typesProxy = $typesProxy;
43
34
  exports.isFunction = isFunction;
44
35
  exports.isObject = isObject;
45
36
  exports.mergeWithoutOverrides = mergeWithoutOverrides;
@@ -1,5 +1,3 @@
1
- import { createFlatProxy } from './createProxy.mjs';
2
-
3
1
  /**
4
2
  * Ensures there are no duplicate keys when building a procedure.
5
3
  * @internal
@@ -30,11 +28,5 @@ function isFunction(fn) {
30
28
  */ function omitPrototype(obj) {
31
29
  return Object.assign(Object.create(null), obj);
32
30
  }
33
- /**
34
- * Prevents access to `$types` at runtime
35
- * @internal
36
- */ const $typesProxy = createFlatProxy((key)=>{
37
- throw new Error(`Tried to access "$types.${key}" which is not available at runtime`);
38
- });
39
31
 
40
- export { $typesProxy, isFunction, isObject, mergeWithoutOverrides, omitPrototype };
32
+ export { isFunction, isObject, mergeWithoutOverrides, omitPrototype };
@@ -60,7 +60,6 @@ exports.getDataTransformer = transformer.getDataTransformer;
60
60
  exports.transformResult = transformer.transformResult;
61
61
  exports.transformTRPCResponse = transformer.transformTRPCResponse;
62
62
  exports.ERROR_SYMBOL = types.ERROR_SYMBOL;
63
- exports.$typesProxy = utils.$typesProxy;
64
63
  exports.isFunction = utils.isFunction;
65
64
  exports.isObject = utils.isObject;
66
65
  exports.mergeWithoutOverrides = utils.mergeWithoutOverrides;
@@ -18,4 +18,4 @@ export { TRPC_ERROR_CODES_BY_KEY, TRPC_ERROR_CODES_BY_NUMBER } from './unstable-
18
18
  export { parseTRPCMessage } from './unstable-core-do-not-import/rpc/parseTRPCMessage.mjs';
19
19
  export { defaultTransformer, getDataTransformer, transformResult, transformTRPCResponse } from './unstable-core-do-not-import/transformer.mjs';
20
20
  export { ERROR_SYMBOL } from './unstable-core-do-not-import/types.mjs';
21
- export { $typesProxy, isFunction, isObject, mergeWithoutOverrides, omitPrototype } from './unstable-core-do-not-import/utils.mjs';
21
+ export { isFunction, isObject, mergeWithoutOverrides, omitPrototype } from './unstable-core-do-not-import/utils.mjs';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@trpc/server",
3
- "version": "11.0.0-rc.329+fdcb4a7d8",
3
+ "version": "11.0.0-rc.332+67c093749",
4
4
  "description": "The tRPC server library",
5
5
  "author": "KATT",
6
6
  "license": "MIT",
@@ -161,5 +161,5 @@
161
161
  "funding": [
162
162
  "https://trpc.io/sponsor"
163
163
  ],
164
- "gitHead": "fdcb4a7d8168d19f9bcbc816b80db815b06a134c"
164
+ "gitHead": "67c093749590628118cbb68e8de52c15e4a7b126"
165
165
  }
@@ -15,7 +15,6 @@ import {
15
15
  import type { DataTransformerOptions } from './transformer';
16
16
  import { defaultTransformer, getDataTransformer } from './transformer';
17
17
  import type { Unwrap, ValidateShape } from './types';
18
- import { $typesProxy } from './utils';
19
18
 
20
19
  type inferErrorFormatterShape<TType> = TType extends ErrorFormatter<
21
20
  any,
@@ -95,7 +94,7 @@ class TRPCBuilder<TContext extends object, TMeta extends object> {
95
94
  * These are just types, they can't be used at runtime
96
95
  * @internal
97
96
  */
98
- $types: $typesProxy,
97
+ $types: null as any,
99
98
  };
100
99
 
101
100
  {
@@ -34,6 +34,10 @@ export interface Procedure<
34
34
  TDef extends BuiltProcedureDef,
35
35
  > {
36
36
  _def: {
37
+ /**
38
+ * These are just types, they can't be used at runtime
39
+ * @internal
40
+ */
37
41
  $types: {
38
42
  input: TDef['input'];
39
43
  output: TDef['output'];
@@ -30,7 +30,7 @@ import type {
30
30
  Simplify,
31
31
  TypeError,
32
32
  } from './types';
33
- import { $typesProxy, mergeWithoutOverrides } from './utils';
33
+ import { mergeWithoutOverrides } from './utils';
34
34
 
35
35
  type IntersectIfDefined<TType, TWith> = TType extends UnsetMarker
36
36
  ? TWith
@@ -498,7 +498,7 @@ function createResolver(
498
498
  type: _defIn.type,
499
499
  experimental_caller: Boolean(finalBuilder._def.caller),
500
500
  meta: finalBuilder._def.meta,
501
- $types: $typesProxy,
501
+ $types: null as any,
502
502
  };
503
503
 
504
504
  const invoke = createProcedureCaller(finalBuilder._def);
@@ -1,5 +1,3 @@
1
- import { createFlatProxy } from './createProxy';
2
-
3
1
  /**
4
2
  * Ensures there are no duplicate keys when building a procedure.
5
3
  * @internal
@@ -43,13 +41,3 @@ export function omitPrototype<TObj extends Record<string, unknown>>(
43
41
  ): TObj {
44
42
  return Object.assign(Object.create(null), obj);
45
43
  }
46
-
47
- /**
48
- * Prevents access to `$types` at runtime
49
- * @internal
50
- */
51
- export const $typesProxy = createFlatProxy<any>((key) => {
52
- throw new Error(
53
- `Tried to access "$types.${key}" which is not available at runtime`,
54
- );
55
- });