Turn off the Change Focus Window on reload ? #17352
Replies: 3 comments
-
I don't think Vite is triggering this behaviour by default. Do you have code that would re-focus the window, in which HMR would re-trigger that code? |
Beta Was this translation helpful? Give feedback.
-
Fantastic question: // vite.config.js
export default {
build: {
outDir: './dist'
},
server: {
hmr: { overlay: false }
}
}
It looks like this behavior does not exist in chrome, it doesn't force window focus (And move cursor in the case of My window manager.) |
Beta Was this translation helpful? Give feedback.
-
@Charles-Schleich did you find a way to keep focus window in your editor? |
Beta Was this translation helpful? Give feedback.
-
While Running
vite --config vite.config.js
upon saving a file in VSCode, the window focus changes from my Code Editor to my Browser.
How do i disable this behavior ?
Beta Was this translation helpful? Give feedback.
All reactions