Reputation: 5164
How would I write this code so I check for both the truthiness of $text-shadows as well as $shadows?
.btn {
@if $text-shadows {
@include text-shadow-black;
}
@if $shadows {
@include shadow-white;
}
}
To be clear, what I want to achieve is this without nesting:
.btn {
@if $text-shadows {
@if $shadows {
@include text-shadow-black;
}
}
}
Upvotes: 0
Views: 231
Reputation: 68339
You're looking for the and
keyword:
.btn {
@if $text-shadows and $shadows {
@include text-shadow-black;
}
}
Upvotes: 2