Reputation: 211
I am new to scss. What does &- mean in the below code ?
.btn{
border: 0;
font-size: 14px;
font-weight: bold;
&-link {
background-color: $white;
color: $orange;
}
}
Upvotes: 1
Views: 73
Reputation: 1768
This:
.btn{
&-link {
background-color: $white;
color: $orange;
}
}
Will be compiled into:
.btn-link {
background-color: $white;
color: $orange;
}
Reference: https://css-tricks.com/the-sass-ampersand/#modifying-the-ampersand
Upvotes: 1