We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
vitejs
Learn more about funding links in repositories.
Report abuse
1 parent 67e7bf2 commit d806c4aCopy full SHA for d806c4a
packages/vite/src/node/server/middlewares/error.ts
@@ -26,7 +26,8 @@ export function buildErrorMessage(
26
includeStack = true
27
): string {
28
if (err.plugin) args.push(` Plugin: ${colors.magenta(err.plugin)}`)
29
- if (err.id) args.push(` File: ${colors.cyan(err.id)}`)
+ const loc = err.loc ? `:${err.loc.line}:${err.loc.column}` : ''
30
+ if (err.id) args.push(` File: ${colors.cyan(err.id)}${loc}`)
31
if (err.frame) args.push(colors.yellow(pad(err.frame)))
32
if (includeStack && err.stack) args.push(pad(cleanStack(err.stack)))
33
return args.join('\n')
0 commit comments