Skip to content

Commit acdddf6

Browse files
committed
chore: cleanup
1 parent 45d11f4 commit acdddf6

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

packages/plugin-rsc/examples/starter/src/framework/entry.rsc.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -94,12 +94,12 @@ export default async function handler(request: Request): Promise<Response> {
9494
}
9595

9696
// Delegate to SSR environment for html rendering.
97-
// The plugin provides `viteRsc.import` helper to allow loading SSR environment entry module
97+
// The plugin provides `loadModule` helper to allow loading SSR environment entry module
9898
// in RSC environment. however this can be customized by implementing own runtime communication
9999
// e.g. `@cloudflare/vite-plugin`'s service binding.
100-
const ssrEntryModule = await import.meta.viteRsc.import<
100+
const ssrEntryModule = await import.meta.viteRsc.loadModule<
101101
typeof import('./entry.ssr.tsx')
102-
>('./entry.ssr.tsx', { environment: 'ssr' })
102+
>('ssr', 'index')
103103
const ssrResult = await ssrEntryModule.renderHTML(rscStream, {
104104
formState,
105105
// allow quick simulation of javascript disabled browser

packages/plugin-rsc/examples/starter/vite.config.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,9 +46,9 @@ export default defineConfig({
4646
ssr: {
4747
build: {
4848
rollupOptions: {
49-
// input: {
50-
// index: './src/framework/entry.ssr.tsx',
51-
// },
49+
input: {
50+
index: './src/framework/entry.ssr.tsx',
51+
},
5252
},
5353
},
5454
},

0 commit comments

Comments
 (0)