@trpc/next 11.15.1 → 11.15.2-canary.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.
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"type": "module",
|
|
3
3
|
"name": "@trpc/next",
|
|
4
|
-
"version": "11.15.
|
|
4
|
+
"version": "11.15.2-canary.3+c4b1d7458",
|
|
5
5
|
"description": "The tRPC Next.js library",
|
|
6
6
|
"author": "KATT",
|
|
7
7
|
"license": "MIT",
|
|
@@ -107,9 +107,9 @@
|
|
|
107
107
|
],
|
|
108
108
|
"peerDependencies": {
|
|
109
109
|
"@tanstack/react-query": "^5.59.15",
|
|
110
|
-
"@trpc/client": "11.15.
|
|
111
|
-
"@trpc/react-query": "11.15.
|
|
112
|
-
"@trpc/server": "11.15.
|
|
110
|
+
"@trpc/client": "11.15.2",
|
|
111
|
+
"@trpc/react-query": "11.15.2",
|
|
112
|
+
"@trpc/server": "11.15.2",
|
|
113
113
|
"next": "*",
|
|
114
114
|
"react": ">=16.8.0",
|
|
115
115
|
"react-dom": ">=16.8.0",
|
|
@@ -126,9 +126,9 @@
|
|
|
126
126
|
"devDependencies": {
|
|
127
127
|
"@tanstack/intent": "^0.0.23",
|
|
128
128
|
"@tanstack/react-query": "^5.80.3",
|
|
129
|
-
"@trpc/client": "11.15.
|
|
130
|
-
"@trpc/react-query": "11.15.
|
|
131
|
-
"@trpc/server": "11.15.
|
|
129
|
+
"@trpc/client": "11.15.2",
|
|
130
|
+
"@trpc/react-query": "11.15.2",
|
|
131
|
+
"@trpc/server": "11.15.2",
|
|
132
132
|
"@types/express": "^5.0.0",
|
|
133
133
|
"@types/node": "^22.13.5",
|
|
134
134
|
"@types/react": "^19.1.0",
|
|
@@ -155,5 +155,5 @@
|
|
|
155
155
|
"bin": {
|
|
156
156
|
"intent": "./bin/intent.js"
|
|
157
157
|
},
|
|
158
|
-
"gitHead": "
|
|
158
|
+
"gitHead": "c4b1d7458ec869f6c51469f7fcd84b517d53ffae"
|
|
159
159
|
}
|
|
@@ -8,7 +8,7 @@ description: >
|
|
|
8
8
|
type: framework
|
|
9
9
|
library: trpc
|
|
10
10
|
framework: react
|
|
11
|
-
library_version: '11.
|
|
11
|
+
library_version: '11.15.1'
|
|
12
12
|
requires:
|
|
13
13
|
- server-setup
|
|
14
14
|
- client-setup
|
|
@@ -337,6 +337,21 @@ export default async function handler(
|
|
|
337
337
|
}
|
|
338
338
|
```
|
|
339
339
|
|
|
340
|
+
### Limiting batch size with maxBatchSize
|
|
341
|
+
|
|
342
|
+
```ts title="pages/api/trpc/[trpc].ts"
|
|
343
|
+
import { createNextApiHandler } from '@trpc/server/adapters/next';
|
|
344
|
+
import { appRouter } from '../../../server/routers/_app';
|
|
345
|
+
|
|
346
|
+
export default createNextApiHandler({
|
|
347
|
+
router: appRouter,
|
|
348
|
+
createContext: () => ({}),
|
|
349
|
+
maxBatchSize: 10,
|
|
350
|
+
});
|
|
351
|
+
```
|
|
352
|
+
|
|
353
|
+
Requests batching more than `maxBatchSize` operations are rejected with a `400 Bad Request` error. Set `maxItems` on your client's `httpBatchLink` to the same value to avoid exceeding the limit.
|
|
354
|
+
|
|
340
355
|
## Common Mistakes
|
|
341
356
|
|
|
342
357
|
### Using ssr: true without understanding implications
|