File tree 3 files changed +4
-3
lines changed
3 files changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -47,6 +47,7 @@ export type {
47
47
ServerHook ,
48
48
ResolvedServerOptions ,
49
49
ResolvedServerUrls ,
50
+ HttpServer ,
50
51
} from './server'
51
52
export type {
52
53
BuildOptions ,
Original file line number Diff line number Diff line change 1
1
import fsp from 'node:fs/promises'
2
2
import path from 'node:path'
3
- import type { Server } from 'node:http'
4
3
import { EventEmitter } from 'node:events'
5
4
import colors from 'picocolors'
6
5
import type { CustomPayload , HMRPayload , Update } from 'types/hmrPayload'
@@ -14,6 +13,7 @@ import { isExplicitImportRequired } from '../plugins/importAnalysis'
14
13
import { getEnvFilesForMode } from '../env'
15
14
import { withTrailingSlash , wrapId } from '../../shared/utils'
16
15
import type { ModuleNode } from './moduleGraph'
16
+ import type { HttpServer } from '.'
17
17
import { restartServerWithUrls } from '.'
18
18
19
19
export const debugHmr = createDebugger ( 'vite:hmr' )
@@ -30,7 +30,7 @@ export interface HmrOptions {
30
30
path ?: string
31
31
timeout ?: number
32
32
overlay ?: boolean
33
- server ?: Server
33
+ server ?: HttpServer
34
34
/** @internal */
35
35
channels ?: HMRChannel [ ]
36
36
}
Original file line number Diff line number Diff line change @@ -139,7 +139,7 @@ export interface ServerOptions extends CommonServerOptions {
139
139
*
140
140
* This is needed to proxy WebSocket connections to the parent server.
141
141
*/
142
- server : http . Server
142
+ server : HttpServer
143
143
}
144
144
/**
145
145
* Options for files served via '/\@fs/'.
You can’t perform that action at this time.
0 commit comments