Tell us what’s happening:
is there something wrong with my code? it keeps saying that my if statement, else if statement did not pass.
I already checked it many times and I don’t see the problem?
Your code so far
<style type='text/scss'>
@mixin border-stroke($val) {
@if $val == light {
light: 1px solid black;
}
@else if $val == medium {
medium: 3px solid black;
}
@else if $val == heavy {
heavy: 6px solid black;
}
@else {
border: none;
}
}
#box {
width: 150px;
height: 150px;
background-color: red;
@include border-stroke(medium);
}
</style>
<div id="box"></div>
Your browser information:
User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/136.0.0.0 Safari/537.36
Challenge Information:
SASS - Use @if and @else to Add Logic To Your Styles