Better HN
topnewbestaskshowjobs
Log inSign up

cng2

5 karma · joined Apr 29, 2015 (11y ago) · 2 submissions

Submissions

comment 11y ago · link · parent

When running a large project, there is never just a single version of a ui element. For example, using media queries, different resolutions, zoom, and print. Or if write your css in oocss with separation of concerns. Being less specific allows your css to be more manageable to change in many different situations. In complicated layouts, cascades are very non-friendly. Styling elements directly also has very high specificity.

comment 11y ago · link · parent

When managing css in large projects, specificity is your worst enemy. ID are not styled, if there are any. If your worried about being semantic for the header and footer, use the html5 header and footer tags.