File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed
Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -142,8 +142,9 @@ The default SSR Node module runner is not exposed. You can use `createNodeEnviro
142142` ` ` js
143143import {
144144 createServer ,
145+ createServerHotChannel ,
145146 createServerModuleRunner ,
146- createNodeEnvironment ,
147+ createNodeDevEnvironment ,
147148} from ' vite'
148149
149150const server = await createServer ({
@@ -154,7 +155,11 @@ const server = await createServer({
154155 dev: {
155156 // Default Vite SSR environment can be overridden in the config, so
156157 // make sure you have a Node environment before the request is received.
157- createEnvironment: createNodeEnvironment ,
158+ createEnvironment(name , config ) {
159+ return createNodeDevEnvironment (name , config , {
160+ hot: createServerHotChannel (),
161+ })
162+ },
158163 },
159164 },
160165 },
You can’t perform that action at this time.
0 commit comments