diff --git a/packages/vite/src/vite.ts b/packages/vite/src/vite.ts index 5280bbd41..78dc2e570 100644 --- a/packages/vite/src/vite.ts +++ b/packages/vite/src/vite.ts @@ -153,7 +153,7 @@ export default function VitePluginVueDevTools(options?: VitePluginVueDevToolsOpt tags: [ { tag: 'script', - injectTo: 'head', + injectTo: 'head-prepend', attrs: { type: 'module', src: `${config.base || '/'}@id/virtual:vue-devtools-path:overlay.js`, @@ -162,7 +162,7 @@ export default function VitePluginVueDevTools(options?: VitePluginVueDevToolsOpt // inject inspector script manually to ensure it's loaded after vue-devtools { tag: 'script', - injectTo: 'head', + injectTo: 'head-prepend', attrs: { type: 'module', src: `${config.base || '/'}@id/virtual:vue-inspector-path:load.js`,