Skip to content

Commit 45e686e

Browse files
authored
fix: sourceMappingURL were incorrect .ts → .js (#2330)
1 parent 332b84d commit 45e686e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

scripts/build.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ function buildFile(file, silent) {
108108
let {code, map} = babel.transformFileSync(file, options);
109109

110110
if (!file.endsWith('.d.ts') && map.sources.length > 0) {
111-
code = `${code}\n\n//# sourceMappingURL=${fileName}.map`;
111+
code = `${code}\n\n//# sourceMappingURL=${destPath}.map`;
112112
map.sources = [path.relative(path.dirname(destPath), file)];
113113
fs.writeFileSync(`${destPath}.map`, JSON.stringify(map));
114114
}

0 commit comments

Comments
 (0)