Skip to content
This repository was archived by the owner on Sep 19, 2025. It is now read-only.

Commit 6cc8e0d

Browse files
Switch absolute source references back to relative paths from the compilation root
1 parent 61cdc27 commit 6cc8e0d

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

lib/gulp/index.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -196,6 +196,11 @@ module.exports = function(initOptions) {
196196

197197
for (var i = 0; i < outputFiles.length; i++) {
198198
if (outputFiles[i].sourceMap) {
199+
if (outputFiles[i].sourceMap.sources) {
200+
outputFiles[i].sourceMap.sources = outputFiles[i].sourceMap.sources.map(function(sourcePath) {
201+
return path.isAbsolute(sourcePath[0]) ? sourcePath.substr(1) : sourcePath;
202+
});
203+
}
199204
applySourceMap(outputFiles[i], outputFiles[i].sourceMap);
200205
}
201206
this.push(outputFiles[i]);

0 commit comments

Comments
 (0)