Can't discard duplicate rules
code: body { padding: 50px; }
body { padding: 0; }
results: body{padding:50px;padding:0}
What can I do to get the results as: body {padding:0}
Currently it's not supported; I need more data before I can do this feature well. Not sure when I'll have time for this as my open source time is very limited these days.
:+1: on this issue... gulp-minify-css didn't have this problem. Having duplicate styles like this is basically broken/poorly written css, but if you could protect us from ourselves or the junior members of our teams, that would be great.
Yep, have had a few enquires about this, and a pull request which didn't quite have the robustness that I am looking for this feature. It's coming, but any help would be greatly appreciated.
https://github.com/ben-eb/postcss-discard-duplicates/pull/4
If you're interested in helping this issue move forward, you can help out by contributing to https://github.com/ben-eb/css-values, which we will be using to validate properties before merging.