diff --git a/packages/vite/index.cjs b/packages/vite/index.cjs index 70515aa90c7a8d..82cdb6ac8a3f5e 100644 --- a/packages/vite/index.cjs +++ b/packages/vite/index.cjs @@ -45,6 +45,7 @@ const disallowedVariables = [ // can be exposed, but doesn't make sense as it's Environment API related 'createServerHotChannel', 'createServerModuleRunner', + 'createServerModuleRunnerTransport', 'isRunnableDevEnvironment', ] disallowedVariables.forEach((name) => { diff --git a/packages/vite/src/node/index.ts b/packages/vite/src/node/index.ts index 69f47f3164c148..0064bdcb7f7c40 100644 --- a/packages/vite/src/node/index.ts +++ b/packages/vite/src/node/index.ts @@ -34,7 +34,10 @@ export { export { BuildEnvironment } from './build' export { fetchModule, type FetchModuleOptions } from './ssr/fetchModule' -export { createServerModuleRunner } from './ssr/runtime/serverModuleRunner' +export { + createServerModuleRunner, + createServerModuleRunnerTransport, +} from './ssr/runtime/serverModuleRunner' export { createServerHotChannel } from './server/hmr' export { ssrTransform as moduleRunnerTransform } from './ssr/ssrTransform' export type { ModuleRunnerTransformOptions } from './ssr/ssrTransform' @@ -169,6 +172,9 @@ export type { HotChannel, ServerHotChannel, HotChannelClient, + NormalizedHotChannel, + NormalizedHotChannelClient, + NormalizedServerHotChannel, } from './server/hmr' export type { FetchFunction, FetchResult } from 'vite/module-runner'