From the course: Sass Essential Training
Unlock this course with a free trial
Join today to access over 25,300 courses taught by industry experts.
Operators and conditionals - Sass Tutorial
From the course: Sass Essential Training
Operators and conditionals
- [Instructor] Every programing language has a series of operators and math functions to help you take care of places where you need to do calculations. Now, in addition Sass has some special operators that can also help you compare and make decisions within your code. Let's take a look at both of those. Now, Sass has the traditional operators that you expect from math. So, things like the addition, subtraction, division, equals as well as the modules operator, what gives you the remainder of a division. Now, the slash is a little bit strange in Sass. Sometimes it refers to a list and sometimes it refers to a division. And it does pretty good job of figuring out when you want to do either. However, in the future, the slash operator will be replaced by math.div. Which makes it a little bit inconvenient, because instead of just using the slash to divide things, you'll have to use math.div, and then put a couple of…
Contents
-
-
-
-
-
(Locked)
Interpolation2m 22s
-
(Locked)
Placeholder selectors1m 29s
-
(Locked)
Comments1m 52s
-
(Locked)
Using lists9m 21s
-
(Locked)
Each2m 47s
-
(Locked)
For2m 1s
-
(Locked)
Maps5m 1s
-
(Locked)
Operators and conditionals5m 57s
-
(Locked)
Color functions4m 27s
-
(Locked)
Challenge: Badges1m 36s
-
(Locked)
Solution: Badges8m 43s
-
(Locked)
-