We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b5cd8c8 commit 5d4e82dCopy full SHA for 5d4e82d
packages/vite/src/node/utils.ts
@@ -166,10 +166,7 @@ export function prettifyUrl(url: string, root: string) {
166
url = removeTimestampQuery(url)
167
const isAbsoluteFile = url.startsWith(root)
168
if (isAbsoluteFile || url.startsWith(FS_PREFIX)) {
169
- let file = path.relative(
170
- root,
171
- isAbsoluteFile ? url : url.slice(FS_PREFIX.length)
172
- )
+ let file = path.relative(root, isAbsoluteFile ? url : fsPathFromId(url))
173
const seg = file.split('/')
174
const npmIndex = seg.indexOf(`node_modules`)
175
const isSourceMap = file.endsWith('.map')
0 commit comments