Skip to content

Commit 367f180

Browse files
authored
fix(index): do not emit sourceMap warning when explicitly set to false
1 parent 2484275 commit 367f180

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: lib/index.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ module.exports = function loader (css, map, meta) {
137137
css = this.exec(css, this.resource)
138138
}
139139

140-
if (!sourceMap && map) {
140+
if (!sourceMap && sourceMap !== false && map) {
141141
this.emitWarning(`\n\n ⚠️ PostCSS Loader\n\nPrevious source map found, but options.sourceMap isn't set.\nIn this case the loader will discard the source map entirely for performance reasons.\nSee https://github.com/postcss/postcss-loader#sourcemap for more information.\n\n`)
142142
}
143143

0 commit comments

Comments
 (0)