Skip to content

Commit 30c5aa0

Browse files
Update packages/plugin-vue/src/main.ts
Co-authored-by: 翠 <[email protected]>
1 parent fd27bad commit 30c5aa0

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

packages/plugin-vue/src/main.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -196,9 +196,10 @@ export async function transformMain(
196196

197197
let resolvedMap: RawSourceMap | undefined = undefined
198198
if (options.sourceMap) {
199+
// the mappings of the source map for the inlined template should be moved
200+
// because the position does not include the script tag part.
201+
// we also concatenate the two source maps while doing that.
199202
if (templateMap) {
200-
// if the template is inlined into the main module (indicated by the presence
201-
// of templateMap), we need to concatenate the two source maps.
202203
const from = scriptMap ?? {
203204
file: filename,
204205
sourceRoot: '',

0 commit comments

Comments
 (0)