maximkoretskiy / postcss-autoreset

PostCSS plugin for automatic rules isolation
MIT License
244 stars 11 forks source link

Put all resets to one rule #4

Closed ai closed 8 years ago

ai commented 8 years ago

Right now we insert reset properties directly to rule. As result after postcss-intial we have long list of properties in rule. Of course, it is not a problem for CSS size because of gzip, but it is a problem for DevTool inspecting.

My suggestion. Input:

.a {
  color: black;
}
.b {
  color: white;
}

Output:

.a, .b {
  all: initial;
}
.a {
  color: black;
}
.b {
  color: white;
}
ai commented 8 years ago

@maximkoretskiy this idea came from @DanGamble89