Skip to content

Commit e522409

Browse files
committed
Changed for consistency
Want all the app code to look as similar as possible across all navigation rsc examples
1 parent c99ea1f commit e522409

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

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

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import HmrProvider from './HmrProvider'
44
import People from './People'
55
import Person from './Person'
66

7-
export function App({ url }: any) {
7+
const App = async ({ url }: any) => {
88
return (
99
<html>
1010
<head>
@@ -25,3 +25,5 @@ export function App({ url }: any) {
2525
</html>
2626
)
2727
}
28+
29+
export default App;

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ export default async function handler(request: Request): Promise<Response> {
1818
} else {
1919
let reqUrl = new URL(request.url);
2020
url = `${reqUrl.pathname}${reqUrl.search}`;
21-
const { App } = await import('./App.tsx');
21+
const App = (await import('./App.tsx')).default;
2222
view = <App url={url} />;
2323
}
2424
const { NavigationHandler } = await import('navigation-react');

0 commit comments

Comments
 (0)