Compiling Sass Flashcards

1
Q

How do you compile scss code into css so that the computer can understand it and the code can be excuted?

A

In the terminal, you type sass filename scss filename css.
For example: sass main.scss main.css
scss

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

How would you nest a class inside of another class in a scss file, in order to save time typing the same property attributes for another class?

A
.parent {
color: #FFF;
.child {
font-size: 12px;
}
}
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

How would you nest a property inside of another property in scss, to save time lets say writing out the border top and bottom?

A
.container {
border : {
top: 4px solid orange;
bottom: 4px solid orange;
}
}
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

How do you create a variable in a scss file? Explain why they are useful.

A

$translucent-white:
rgba(255,255,255,0.3);

.slogan {
background-color: $translucent-white;
}

Variables can be very useful, because say you have multiple classes where the font color all has to be the same, and you want to change it. Assigning those cl

How well did you know this?
1
Not at all
2
3
4
5
Perfectly