@trpc/react-query 11.0.0-alpha-tmp-app-router-example.384 → 11.0.0-alpha-tmp-app-router-example.388
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/bundle-analysis.json +14 -14
- package/dist/rsc.d.ts +3 -0
- package/dist/rsc.d.ts.map +1 -1
- package/dist/rsc.js +3 -1
- package/dist/rsc.mjs +3 -1
- package/package.json +8 -8
- package/src/rsc.tsx +3 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
|
-
"bundleSize":
|
|
3
|
-
"bundleOrigSize":
|
|
4
|
-
"bundleReduction": 52.
|
|
2
|
+
"bundleSize": 32270,
|
|
3
|
+
"bundleOrigSize": 68448,
|
|
4
|
+
"bundleReduction": 52.85,
|
|
5
5
|
"modules": [
|
|
6
6
|
{
|
|
7
7
|
"id": "/src/shared/hooks/createHooksInternal.tsx",
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
"dependents": [
|
|
15
15
|
"/src/createTRPCReact.tsx"
|
|
16
16
|
],
|
|
17
|
-
"percent": 42.
|
|
17
|
+
"percent": 42.59,
|
|
18
18
|
"reduction": 12.84
|
|
19
19
|
},
|
|
20
20
|
{
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
"/src/createTRPCQueryUtils.tsx",
|
|
30
30
|
"/src/shared/hooks/createHooksInternal.tsx"
|
|
31
31
|
],
|
|
32
|
-
"percent": 11.
|
|
32
|
+
"percent": 11.72,
|
|
33
33
|
"reduction": 6.34
|
|
34
34
|
},
|
|
35
35
|
{
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
"dependents": [
|
|
44
44
|
"/src/server/index.ts"
|
|
45
45
|
],
|
|
46
|
-
"percent": 11.
|
|
46
|
+
"percent": 11.38,
|
|
47
47
|
"reduction": 50.38
|
|
48
48
|
},
|
|
49
49
|
{
|
|
@@ -59,20 +59,20 @@
|
|
|
59
59
|
"dependents": [
|
|
60
60
|
"/src/shared/index.ts"
|
|
61
61
|
],
|
|
62
|
-
"percent": 8.
|
|
62
|
+
"percent": 8.89,
|
|
63
63
|
"reduction": 74.38
|
|
64
64
|
},
|
|
65
65
|
{
|
|
66
66
|
"id": "/src/rsc.tsx",
|
|
67
|
-
"size":
|
|
68
|
-
"origSize":
|
|
67
|
+
"size": 2839,
|
|
68
|
+
"origSize": 5008,
|
|
69
69
|
"renderedExports": [
|
|
70
70
|
"createHydrationHelpers"
|
|
71
71
|
],
|
|
72
72
|
"removedExports": [],
|
|
73
73
|
"dependents": [],
|
|
74
|
-
"percent": 8.
|
|
75
|
-
"reduction": 43.
|
|
74
|
+
"percent": 8.8,
|
|
75
|
+
"reduction": 43.31
|
|
76
76
|
},
|
|
77
77
|
{
|
|
78
78
|
"id": "/src/internals/getQueryKey.ts",
|
|
@@ -91,7 +91,7 @@
|
|
|
91
91
|
"/src/shared/proxy/useQueriesProxy.ts",
|
|
92
92
|
"/src/shared/hooks/createHooksInternal.tsx"
|
|
93
93
|
],
|
|
94
|
-
"percent": 6.
|
|
94
|
+
"percent": 6.19,
|
|
95
95
|
"reduction": 42.49
|
|
96
96
|
},
|
|
97
97
|
{
|
|
@@ -106,7 +106,7 @@
|
|
|
106
106
|
"dependents": [
|
|
107
107
|
"/src/index.ts"
|
|
108
108
|
],
|
|
109
|
-
"percent": 2.
|
|
109
|
+
"percent": 2.63,
|
|
110
110
|
"reduction": 89.28
|
|
111
111
|
},
|
|
112
112
|
{
|
|
@@ -135,7 +135,7 @@
|
|
|
135
135
|
"/src/shared/index.ts",
|
|
136
136
|
"/src/shared/hooks/createHooksInternal.tsx"
|
|
137
137
|
],
|
|
138
|
-
"percent": 1.
|
|
138
|
+
"percent": 1.76,
|
|
139
139
|
"reduction": 82.03
|
|
140
140
|
},
|
|
141
141
|
{
|
package/dist/rsc.d.ts
CHANGED
|
@@ -14,6 +14,9 @@ type DecorateRouterRecord<TRoot extends AnyRootTypes, TRecord extends RouterReco
|
|
|
14
14
|
[TKey in keyof TRecord]: TRecord[TKey] extends AnyProcedure ? DecorateProcedure<TRoot, TRecord[TKey]> : TRecord[TKey] extends RouterRecord ? DecorateRouterRecord<TRoot, TRecord[TKey]> : never;
|
|
15
15
|
};
|
|
16
16
|
type Caller<TRouter extends AnyRouter> = ReturnType<RouterCaller<inferRouterRootTypes<TRouter>, TRouter['_def']['record']>>;
|
|
17
|
+
/**
|
|
18
|
+
* @note This requires `@tanstack/react-query@^5.45.0`
|
|
19
|
+
*/
|
|
17
20
|
export declare function createHydrationHelpers<TRouter extends AnyRouter>(caller: AnyRouter extends TRouter ? TypeError<'Generic parameter missing in `createHydrationHelpers<HERE>`'> : Caller<TRouter>, getQueryClient: () => QueryClient): {
|
|
18
21
|
/***
|
|
19
22
|
* Wrapped caller with prefetch helpers
|
package/dist/rsc.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"rsc.d.ts","sourceRoot":"","sources":["../src/rsc.tsx"],"names":[],"mappings":"AAAA,OAAO,EAGL,KAAK,WAAW,EACjB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AACpD,OAAO,KAAK,EAAE,+BAA+B,EAAE,MAAM,cAAc,CAAC;AACpE,OAAO,EAEL,KAAK,SAAS,EACd,KAAK,mBAAmB,EACxB,KAAK,YAAY,EAClB,MAAM,0CAA0C,CAAC;AAClD,OAAO,KAAK,EACV,YAAY,EACZ,YAAY,EACZ,oBAAoB,EACpB,oBAAoB,EAEpB,YAAY,EACZ,SAAS,EACV,MAAM,0CAA0C,CAAC;AAClD,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,OAAO,KAAK,EACV,6BAA6B,EAC7B,qBAAqB,EACtB,MAAM,UAAU,CAAC;AAIlB,KAAK,iBAAiB,CACpB,KAAK,SAAS,YAAY,EAC1B,UAAU,SAAS,YAAY,IAC7B;IACF,CAAC,KAAK,EAAE,mBAAmB,C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/B,+BAA+B,CAAC,KAAK,EAAE,UAAU,CAAC,EAClD,eAAe,CAAC,KAAK,CAAC,CACvB,KACE,OAAO,CAAC,IAAI,CAAC,CAAC;CACpB,CAAC;AAEF,KAAK,oBAAoB,CACvB,KAAK,SAAS,YAAY,EAC1B,OAAO,SAAS,YAAY,IAC1B;KACD,IAAI,IAAI,MAAM,OAAO,GAAG,OAAO,CAAC,IAAI,CAAC,SAAS,YAAY,GACvD,iBAAiB,CAAC,KAAK,EAAE,OAAO,CAAC,IAAI,CAAC,CAAC,GACvC,OAAO,CAAC,IAAI,CAAC,SAAS,YAAY,GAClC,oBAAoB,CAAC,KAAK,EAAE,OAAO,CAAC,IAAI,CAAC,CAAC,GAC1C,KAAK;CACV,CAAC;AAEF,KAAK,MAAM,CAAC,OAAO,SAAS,SAAS,IAAI,UAAU,CACjD,YAAY,CAAC,oBAAoB,CAAC,OAAO,CAAC,EAAE,OAAO,CAAC,MAAM,CAAC,CAAC,QAAQ,CAAC,CAAC,CACvE,CAAC;AAGF;;GAEG;AACH,wBAAgB,sBAAsB,CAAC,OAAO,SAAS,SAAS,EAC9D,MAAM,EAAE,SAAS,SAAS,OAAO,GAC7B,SAAS,CAAC,6DAA6D,CAAC,GACxE,MAAM,CAAC,OAAO,CAAC,EACnB,cAAc,EAAE,MAAM,WAAW;IA2D/B;;;;;;;;;;;OAWG;;IAEH;;;;;;;;;;;;;;;;;;;;;;;;OAwBG;2BAhDyB;QAAE,QAAQ,EAAE,MAAM,SAAS,CAAA;KAAE;EAmD5D"}
|
package/dist/rsc.js
CHANGED
|
@@ -29,7 +29,9 @@ const HELPERS = [
|
|
|
29
29
|
'prefetchInfinite'
|
|
30
30
|
];
|
|
31
31
|
// ts-prune-ignore-next
|
|
32
|
-
|
|
32
|
+
/**
|
|
33
|
+
* @note This requires `@tanstack/react-query@^5.45.0`
|
|
34
|
+
*/ function createHydrationHelpers(caller, getQueryClient) {
|
|
33
35
|
const wrappedProxy = unstableCoreDoNotImport.createRecursiveProxy(async ({ path , args })=>{
|
|
34
36
|
const proc = path.reduce((acc, key)=>// @ts-expect-error - ??
|
|
35
37
|
HELPERS.includes(key) ? acc : acc[key], caller);
|
package/dist/rsc.mjs
CHANGED
|
@@ -8,7 +8,9 @@ const HELPERS = [
|
|
|
8
8
|
'prefetchInfinite'
|
|
9
9
|
];
|
|
10
10
|
// ts-prune-ignore-next
|
|
11
|
-
|
|
11
|
+
/**
|
|
12
|
+
* @note This requires `@tanstack/react-query@^5.45.0`
|
|
13
|
+
*/ function createHydrationHelpers(caller, getQueryClient) {
|
|
12
14
|
const wrappedProxy = createRecursiveProxy(async ({ path , args })=>{
|
|
13
15
|
const proc = path.reduce((acc, key)=>// @ts-expect-error - ??
|
|
14
16
|
HELPERS.includes(key) ? acc : acc[key], caller);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@trpc/react-query",
|
|
3
|
-
"version": "11.0.0-alpha-tmp-app-router-example.
|
|
3
|
+
"version": "11.0.0-alpha-tmp-app-router-example.388+2b04d6593",
|
|
4
4
|
"description": "The tRPC React library",
|
|
5
5
|
"author": "KATT",
|
|
6
6
|
"license": "MIT",
|
|
@@ -63,16 +63,16 @@
|
|
|
63
63
|
}
|
|
64
64
|
},
|
|
65
65
|
"peerDependencies": {
|
|
66
|
-
"@tanstack/react-query": "^5.
|
|
67
|
-
"@trpc/client": "11.0.0-alpha-tmp-app-router-example.
|
|
68
|
-
"@trpc/server": "11.0.0-alpha-tmp-app-router-example.
|
|
66
|
+
"@tanstack/react-query": "^5.40.0",
|
|
67
|
+
"@trpc/client": "11.0.0-alpha-tmp-app-router-example.388+2b04d6593",
|
|
68
|
+
"@trpc/server": "11.0.0-alpha-tmp-app-router-example.388+2b04d6593",
|
|
69
69
|
"react": ">=18.2.0",
|
|
70
70
|
"react-dom": ">=18.2.0"
|
|
71
71
|
},
|
|
72
72
|
"devDependencies": {
|
|
73
|
-
"@tanstack/react-query": "^5.
|
|
74
|
-
"@trpc/client": "11.0.0-alpha-tmp-app-router-example.
|
|
75
|
-
"@trpc/server": "11.0.0-alpha-tmp-app-router-example.
|
|
73
|
+
"@tanstack/react-query": "^5.45.0",
|
|
74
|
+
"@trpc/client": "11.0.0-alpha-tmp-app-router-example.388+2b04d6593",
|
|
75
|
+
"@trpc/server": "11.0.0-alpha-tmp-app-router-example.388+2b04d6593",
|
|
76
76
|
"@types/express": "^4.17.17",
|
|
77
77
|
"@types/node": "^20.10.0",
|
|
78
78
|
"@types/react": "^18.3.1",
|
|
@@ -92,5 +92,5 @@
|
|
|
92
92
|
"funding": [
|
|
93
93
|
"https://trpc.io/sponsor"
|
|
94
94
|
],
|
|
95
|
-
"gitHead": "
|
|
95
|
+
"gitHead": "2b04d659340f9d18d0a8138a09da7f9c54985787"
|
|
96
96
|
}
|
package/src/rsc.tsx
CHANGED
|
@@ -69,6 +69,9 @@ type Caller<TRouter extends AnyRouter> = ReturnType<
|
|
|
69
69
|
>;
|
|
70
70
|
|
|
71
71
|
// ts-prune-ignore-next
|
|
72
|
+
/**
|
|
73
|
+
* @note This requires `@tanstack/react-query@^5.45.0`
|
|
74
|
+
*/
|
|
72
75
|
export function createHydrationHelpers<TRouter extends AnyRouter>(
|
|
73
76
|
caller: AnyRouter extends TRouter
|
|
74
77
|
? TypeError<'Generic parameter missing in `createHydrationHelpers<HERE>`'>
|