We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7495074 commit 03b77bdCopy full SHA for 03b77bd
packages/vite/src/node/server/hmr.ts
@@ -50,7 +50,7 @@ export async function handleHMRUpdate(
50
const isConfigDependency = config.configFileDependencies.some(
51
(name) => file === path.resolve(name)
52
)
53
- const isEnv = config.inlineConfig.envFile !== false && file.endsWith('.env')
+ const isEnv = config.inlineConfig.envFile !== false && (file === '.env' || file.startsWith('.env.'))
54
if (isConfig || isConfigDependency || isEnv) {
55
// auto restart server
56
debugHmr(`[config change] ${chalk.dim(shortFile)}`)
0 commit comments