Ternary Operators can clean up your code

JavaScript Syntax for ternary operators

(condition) ? true : false;

Use Case

Consider a situation where you need to work with 3 variables where the assignment of one variable depends upon comparing the other 2 variables. Continue reading “Ternary Operators can clean up your code”