Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Autoprefix webkit not present with webpack -p mode #134

Closed
JiDai opened this issue Nov 9, 2016 · 3 comments
Closed

Autoprefix webkit not present with webpack -p mode #134

JiDai opened this issue Nov 9, 2016 · 3 comments

Comments

@JiDai
Copy link

JiDai commented Nov 9, 2016

Hi,

I have a simple SCSS file for testing :

body{
  display:flex;
  flex:1;
}

I have this config in webpack :

{
  test: /\.scss$/,
  loaders: ['style', 'css?importLoaders=1','postcss', 'resolve-url', 'sass?sourceMap']
},

Output this with running webpack

body {\n  display: -webkit-flex;\n  display: -ms-flexbox;\n  display: flex;\n  -webkit-flex: 1;\n      -ms-flex: 1;\n          flex: 1;\n}\n\n/

But output this with webpack -p

body{display:-ms-flexbox;display:flex;-ms-flex:1;flex:1}

And here is my postcss.config.js file

module.exports = (ctx) => {
    return {
        map: ctx.env === 'development' ? 'inline' : false,
        plugins: {
            'autoprefixer': {
                'browsers': ['last 2 versions', 'ie > 9', 'iOS 8']
            }
        }
    }
}

Why webkit prefixes is not present with -p flag ?

webpack: 1.13.3
postcss: 5.2.5
postcss-loader: 1.1.0

@ai
Copy link
Contributor

ai commented Nov 9, 2016

@ai ai closed this as completed Nov 9, 2016
@ai
Copy link
Contributor

ai commented Nov 9, 2016

Please support this issue to fix this problem webpack-contrib/css-loader#281

@JiDai
Copy link
Author

JiDai commented Nov 9, 2016

Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants