Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 1e7dd93

Browse filesBrowse files
committed
also repsect external autoprefixer options
1 parent 4d45aed commit 1e7dd93
Copy full SHA for 1e7dd93

File tree

Expand file treeCollapse file tree

1 file changed

+7
-1
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+7
-1
lines changed

‎lib/style-rewriter.js

Copy file name to clipboardExpand all lines: lib/style-rewriter.js
+7-1Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ var postcss = require('postcss')
22
var selectorParser = require('postcss-selector-parser')
33
var hash = require('hash-sum')
44
var loaderUtils = require('loader-utils')
5+
var assign = require('object-assign')
56

67
var currentId
78
var addId = postcss.plugin('add-id', function () {
@@ -42,7 +43,12 @@ module.exports = function (css) {
4243
processors.push(addId)
4344
}
4445
if (autoprefixOptions !== false) {
45-
autoprefixOptions = autoprefixOptions || { remove: false }
46+
autoprefixOptions = assign(
47+
{},
48+
// also respect autoprefixer-loader options
49+
this.options.autoprefixer,
50+
autoprefixOptions
51+
)
4652
var autoprefixer = require('autoprefixer')(autoprefixOptions)
4753
processors.push(autoprefixer)
4854
}

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.