Skip to content

Commit 8c69e5e

Browse files
committed
Changed to match other navigation rsc samples
1 parent de4dd35 commit 8c69e5e

File tree

1 file changed

+3
-3
lines changed
  • packages/plugin-rsc/examples/navigation/src

1 file changed

+3
-3
lines changed

packages/plugin-rsc/examples/navigation/src/client.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1+
import { useState, useMemo } from "react";
2+
import ReactDOM from "react-dom/client";
13
import { hydrate as _hydrate } from '@vitejs/plugin-rsc/extra/browser'
24
import { createFromFetch, createFromReadableStream } from "@vitejs/plugin-rsc/browser";
3-
import { useState, useMemo } from "react";
4-
import ReactDomClient from "react-dom/client";
55
import { BundlerContext } from 'navigation-react';
66

77
declare global{interface Window { __FLIGHT_DATA: any;}}
@@ -37,7 +37,7 @@ async function hydrate() {
3737
</BundlerContext.Provider>
3838
);
3939
}
40-
ReactDomClient.hydrateRoot(document, <Shell />);
40+
ReactDOM.hydrateRoot(document, <Shell />);
4141
}
4242
async function fetchRSC(url: string, {body, ...options}: any) {
4343
const payload = await createFromFetch(fetch(url, {...options, body: JSON.stringify(body), method: 'PUT'})) as any;

0 commit comments

Comments
 (0)