Introduction to CSS Architecture and a little SASS
50
CSS Architecture and Sass
-
Upload
roman-kuba -
Category
Education
-
view
287 -
download
1
Transcript of Introduction to CSS Architecture and a little SASS
Basics
. Selects elements by class
# Selects elements by an ID
> Selects a direct child
~ Selects following siblings
+ Selects direct sibling
<div class="comment comment--favorite"> <img src="..." alt="" class="comment__user"> <p class="comment__body"> ... </p> </div>
IDs can and shall be used, but of watch out: IDs have to be unique to your page so be certain you don't need it again.
Groundrules
• Don't nest deeper than 3 Levels
• Don't nest IDs
• Use classes whenever possible
• Use Pseudo Selectors for complex issues
Create HTML and CSS for a TODO Page and put it in your git Repository.
(Form, Todos, Unchecked and Checked)
http://codepen.io/Codebryo/pen/qAjIv