Skip to content

Commit 2ba91fd

Browse files
committed
fix: #112 - update source maps for new sass version
1 parent ac1d87c commit 2ba91fd

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

utils/renderPostcss.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ module.exports = function renderPostcss(input, outFile, config, cb) {
88
// try to dynamic load of postcss plugins
99
/* eslint-disable */
1010
const runPlugins = plugins.map(plugin => require(plugin));
11-
const map = config.general.isProduction ? false : { inline: true, prev: input.map.toString() } ;
11+
const map = config.general.isProduction ? false : { inline: true, prev: input.sourceMap } ;
1212

1313
/* eslint-enable */
1414
// run postcss plugins at sass output

utils/renderSass.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ module.exports = function renderSass(dest, file, config, cb, write = false) {
3636

3737
// if is dev add source maps
3838
if (!config.general.isProduction && write) {
39-
writeFile(`${outFile}.map`, result.map, true);
39+
writeFile(`${outFile}.map`, JSON.stringify(result.sourceMap), true);
4040
}
4141

4242
// pass the destination relative for map
@@ -57,4 +57,4 @@ module.exports = function renderSass(dest, file, config, cb, write = false) {
5757
return;
5858
}
5959
});
60-
};
60+
};

0 commit comments

Comments
 (0)