Skip to content

Commit c583927

Browse files
authored
fix(config): make debugger work with bundle loader (vitejs#20573)
1 parent 20d4817 commit c583927

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/vite/src/node/config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1938,7 +1938,7 @@ async function bundleConfigFile(
19381938
mainFields: ['main'],
19391939
sourcemap: 'inline',
19401940
// the last slash is needed to make the path correct
1941-
sourceRoot: path.dirname(fileName) + path.sep,
1941+
sourceRoot: pathToFileURL(path.dirname(fileName)).href + '/',
19421942
metafile: true,
19431943
define: {
19441944
__dirname: dirnameVarName,

0 commit comments

Comments
 (0)