rewriteTraceLine() — vue Function Reference
Architecture documentation for the rewriteTraceLine() function in source-map-support.ts from the vue codebase.
Entity Profile
Dependency Diagram
graph TD 1b5d5aea_9a50_8b54_9abf_7dc53946b0d0["rewriteTraceLine()"] 033504a0_f5ab_68bb_f001_520285afc234["source-map-support.ts"] 1b5d5aea_9a50_8b54_9abf_7dc53946b0d0 -->|defined in| 033504a0_f5ab_68bb_f001_520285afc234 02eb7214_df43_ba24_39b9_3d27ac2985a7["rewriteErrorTrace()"] 02eb7214_df43_ba24_39b9_3d27ac2985a7 -->|calls| 1b5d5aea_9a50_8b54_9abf_7dc53946b0d0 style 1b5d5aea_9a50_8b54_9abf_7dc53946b0d0 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
packages/server-renderer/src/bundle-renderer/source-map-support.ts lines 29–55
function rewriteTraceLine(
trace: string,
mapConsumers: {
[key: string]: typeof SourceMapConsumer
}
) {
const m = trace.match(filenameRE)
const map = m && mapConsumers[m[1]]
if (m != null && map) {
const originalPosition = map.originalPositionFor({
line: Number(m[2]),
column: Number(m[3])
})
if (originalPosition.source != null) {
const { source, line, column } = originalPosition
const mappedPosition = `(${source.replace(
/^webpack:\/\/\//,
''
)}:${String(line)}:${String(column)})`
return trace.replace(filenameRE, mappedPosition)
} else {
return trace
}
} else {
return trace
}
}
Domain
Subdomains
Called By
Source
Frequently Asked Questions
What does rewriteTraceLine() do?
rewriteTraceLine() is a function in the vue codebase, defined in packages/server-renderer/src/bundle-renderer/source-map-support.ts.
Where is rewriteTraceLine() defined?
rewriteTraceLine() is defined in packages/server-renderer/src/bundle-renderer/source-map-support.ts at line 29.
What calls rewriteTraceLine()?
rewriteTraceLine() is called by 1 function(s): rewriteErrorTrace.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free