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

Remove Autoprefixer from cssnano #281

Closed
ai opened this issue May 27, 2016 · 17 comments
Closed

Remove Autoprefixer from cssnano #281

ai opened this issue May 27, 2016 · 17 comments

Comments

@ai
Copy link
Contributor

ai commented May 27, 2016

css-loader contains cssnano to compress CSS. cssnano by default contains Autoprefixer to remove all prefixes. It works great when you undertand what you want to do. But because css minifier feature is hidden inside webpack many people don’t expect that webpack will remove prefixes.

Right now I have so many issues in Autoprefixer repo about this issue.

So I suggest to remove autoprefixer rule from cssnano in css-loader.

@ben-eb do you agree as cssnano author?

@sokra we have problem right now, because in latest Can I Use update iOS 8 was removed from default last 2 versions browsers list and many people are in pain.

@ai
Copy link
Contributor Author

ai commented May 27, 2016

Of course, there is a much better way. Put browserslist config to project root, so every tool will use same browsers (Autoprefixer, cssnano, doiuse, cssnext). But many people don’t know about it.

I posted a tweet about this solution. But your know, people don’t read a docs.

@ai
Copy link
Contributor Author

ai commented May 27, 2016

I added this question to Autoprefixer FAQ, but I still think that we should fix it in css-loader too

@ben-eb
Copy link
Contributor

ben-eb commented May 27, 2016

Sure, if it is causing confusion. 👍

I plan to remove this option anyway for version 4 but it's a while away.

@dmiller9911
Copy link

@ai I am curious if the browserslist still works. I created one, and it seems to be ignored. After doing some digging I found that the path being sent to browserslist is something along the lines of:

c:\css-loader!c:\src\node_modules\postcss-loader\index.js!c:\src\node_modules\less-loader\index.js!c:\src\foo.less

The c:\css-loader seems to be coming from here

The problem with this is that browserslist will tick down each dir until it finds the config file, but with this path it will never find one unless it is sitting in c:.

loader config below:

{ loader: 'style!css!postcss!less', test: /.less$/ }

@ai
Copy link
Contributor Author

ai commented Jun 3, 2016

@dmiller9911 it is a bad place for other issue :). Could you:

  1. Check that you use latest version of postcss-loader (I fixed path issue in previous release)
  2. Create a issue in postcss-loader if you still have a issue.

@robwierzbowski
Copy link

Second this removal. I highly prefer single responsibility packages used as peers. Lessons from the grunt do everything for everyone days.

@ai
Copy link
Contributor Author

ai commented Sep 22, 2016

@sokra do you need PR for it? (It is just one small option).

@ai
Copy link
Contributor Author

ai commented Oct 17, 2016

@sokra ping

@ai
Copy link
Contributor Author

ai commented Oct 17, 2016

@sokra could you say anything? :) It is very sad to have no feedback.

This issue is very important for me, because users write me about it.

@SpaceK33z
Copy link
Contributor

SpaceK33z commented Oct 17, 2016

@ai, sokra has limited time atm since he has holidays. I agree with you here. I can push the fix, but since I don't maintain css-loader (do have permissions though) I want to get feedback from at least one other member of the core team.

@ai
Copy link
Contributor Author

ai commented Oct 17, 2016

@SpaceK33z done #361

@ai
Copy link
Contributor Author

ai commented Nov 9, 2016

Still waiting for release 😉.

Users still report a issue and I need to spend time to explain problem
webpack-contrib/postcss-loader#134

@ai
Copy link
Contributor Author

ai commented Nov 10, 2016

Other example of issue, where we spend time, because this issue is not released webpack-contrib/postcss-loader#81

@ai
Copy link
Contributor Author

ai commented Nov 17, 2016

@SpaceK33z please, write anything about this issue. It is very painful when everyone just ignore you :(.

The new issue in Autoprefixer about this issue: postcss/autoprefixer#747

Please release it. I know that open source developers always don’t have time. But right now I spend my time, because of this issue.

@SpaceK33z
Copy link
Contributor

@ai, I'm really sorry. I didn't have npm publish permissions and it took me a while to get them. I have them now and I'll release a new version today.

@SpaceK33z
Copy link
Contributor

@ai, published 0.26.0. Sorry again, I fully understand your frustrations about how we handled this.

@ai
Copy link
Contributor Author

ai commented Nov 17, 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

5 participants