You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
<docs-warning>This API is experimental and subject to breaking changes in
26
-
minor/patch releases. Please use with caution and pay **very** close attention
25
+
<docs-warning>This API is experimental and subject to breaking changes in
26
+
minor/patch releases. Please use with caution and pay **very** close attention
27
27
to release notes for relevant changes.</docs-warning>
28
28
29
29
## Summary
@@ -43,7 +43,7 @@ import {
43
43
44
44
routeRSCServerRequest({
45
45
request,
46
-
fetchServer,
46
+
serverResponse,
47
47
createFromReadableStream,
48
48
async renderHTML(getPayload) {
49
49
const payload =getPayload();
@@ -53,7 +53,7 @@ routeRSCServerRequest({
53
53
{
54
54
bootstrapScriptContent,
55
55
formState: awaitpayload.formState,
56
-
}
56
+
},
57
57
);
58
58
},
59
59
});
@@ -62,7 +62,9 @@ routeRSCServerRequest({
62
62
## Signature
63
63
64
64
```tsx
65
-
function RSCStaticRouter({ getPayload }:RSCStaticRouterProps)
65
+
function RSCStaticRouter({
66
+
getPayload,
67
+
}:RSCStaticRouterProps);
66
68
```
67
69
68
70
## Props
@@ -71,4 +73,3 @@ function RSCStaticRouter({ getPayload }: RSCStaticRouterProps)
71
73
72
74
A function that starts decoding of the [`unstable_RSCPayload`](https://api.reactrouter.com/v7/types/react_router.unstable_RSCPayload.html). Usually passed
73
75
through from [`unstable_routeRSCServerRequest`](../rsc/routeRSCServerRequest)'s `renderHTML`.
@@ -87,10 +89,9 @@ async function routeRSCServerRequest({
87
89
88
90
Your `react-server-dom-xyz/client`'s `createFromReadableStream` function, used to decode payloads from the server.
89
91
90
-
### opts.fetchServer
92
+
### opts.serverResponse
91
93
92
-
Afunction that forwards a [`Request`](https://developer.mozilla.org/en-US/docs/Web/API/Request) to the [RSC](https://react.dev/reference/rsc/server-components) handler
A Response from the [RSC](https://react.dev/reference/rsc/server-components) handler containing a serialized [`unstable_RSCPayload`](https://api.reactrouter.com/v7/types/react_router.unstable_RSCPayload.html).
94
95
95
96
### opts.hydrate
96
97
@@ -109,4 +110,3 @@ The request to route.
109
110
A [`Response`](https://developer.mozilla.org/en-US/docs/Web/API/Response)
110
111
that either contains the [RSC](https://react.dev/reference/rsc/server-components)
111
112
payload for data requests, or renders the HTML for document requests.
0 commit comments