jareware / css-architecture

8 simple rules for a robust, scalable CSS architecture
2.59k stars 129 forks source link

Global styles #2

Open saltcod opened 8 years ago

saltcod commented 8 years ago

Howdy!

Great post! Really thoughtful, lots of nice ideas.

I'm wondering how you handle global styles? Normalize as one example, or other truly global styles that you might want all over the place.

Thanks!

halian-vilela commented 8 years ago

Fantastic Article!

Regarding Globals, I'm trying to follow the ITCSS methodology myself, so I've set, in the Generic levels, three stylesheets to handle the real globals (_general.scss), typography stuff (_typography.scss) and WordPress inputs and WYSIWYG-related styles (_wpbasics.scss).

footer_js_ _mercadao

Using this I was able to mitigate the necessity for Normalize, so, despite those styles I really use and know what for, I'm not using any reset.

jareware commented 8 years ago

@saltcod thanks, glad you liked it! :)

As to CSS resets, I kind of alluded to them in the 1. Always prefer classes section, but since you're not the only one who was left wondering where they fit into the picture, I'll definitely try to include some clarifications on that part!

jareware commented 8 years ago

@halian-vilela thanks for the feedback!

I wasn't aware of ITCSS, and their landing page wasn't very helpful. ;) Still, anything by Harry Roberts gets serious consideration from me.

But looking at https://www.xfive.co/blog/itcss-scalable-maintainable-css-architecture/, I'm not really sure what you mean by:

Using this I was able to mitigate the necessity for Normalize, so, despite those styles I really use and know what for, I'm not using any reset.

since it specifically talks about resets here:

Generic – reset and/or normalize styles, box-sizing definition, etc. This is the first layer which generates actual CSS.