2

So far, including a CSS reset was a standard step for me at the very beginning of web page designing.

I heard once the opinion that this is bad; however I had no opportunity to ask the guy who said that for the reasons.

Now I'd like to know what drawbacks can you specify.

Paul D. Waite
  • 96,640
  • 56
  • 199
  • 270
migajek
  • 8,524
  • 15
  • 77
  • 116
  • possible duplicate of [Are CSS Frameworks Really Worth Using?](http://stackoverflow.com/questions/506523/are-css-frameworks-really-worth-using) – Pekka Aug 04 '10 at 15:09
  • Good question but already discussed several times. See also http://stackoverflow.com/search?q=css+frameworks – Pekka Aug 04 '10 at 15:10
  • 1
    I don't really want to talk about CSS frameworks. the difference between the reset and the complete css framework is the overhead which comes with the layout / grid styles. – migajek Aug 04 '10 at 15:28
  • 1
    I'm sorry, I must have been sleeping. Resets, however, have also been discussed before, even more extensively than frameworks. This is probably the best one: http://stackoverflow.com/questions/167531/is-it-ok-to-use-a-css-reset-stylesheet more here: http://stackoverflow.com/search?q=css+reset – Pekka Aug 04 '10 at 15:30
  • I don’t see any specifically asking for drawbacks though. I’d keep this question. – Paul D. Waite Aug 04 '10 at 22:39

2 Answers2

3

Using a CSS reset means you, in many cases, will have many rules that are not necessary. You will first set body { margin: 0; padding: 0; } in reset.css and then set body { margin: 0 auto; padding: 20px; } in style.css or something, when only specifying the latter would give the same result. And will you really use all those obscure elements that are included in the reset?

What I sometimes do is that I add a reset.css, start coding, and then I check my page in Dragonfly or Firebug and there I will see which rules from reset.css are overridden. Those I can remove from reset.css, and in the end the file is likely to be very small or empty.

Jacob Rask
  • 22,804
  • 8
  • 38
  • 36
  • 1
    Your method sounds good. One question though — how big is the “unnecessary rules” issue? Have you saved a lot of bandwidth removing the overridden rules? I would have thought with any reasonably substantial stylesheet, it’d be a pretty small percentage. – Paul D. Waite Aug 04 '10 at 22:38
0

I dont think there is any problems with css resets as a concept.
The only problem maybe using the wrong reset like the * reset which may have performance penalty for the browser.
If using something like Eric Meyer's css reset http://meyerweb.com/eric/tools/css/reset/index.html then you wont have any problems.
The other advice is you can tweak the reset to your specific needs and not treat it as a read only file :).

Karim
  • 6,113
  • 18
  • 58
  • 83