Answer the question
In order to leave comments, you need to log in
BEM Modifiers, am I doing it right?
There is a structure:
.btn
.btn__i
.btn_span
/* белый модификатор */
.btn--red{
bg: red;
}
.btn--red__i{
color: white;
}
/* серый */
.btn--grey{
bg: grey;
}
.btn--red__i{
color: black;
}
Answer the question
In order to leave comments, you need to log in
Firstly, it makes sense to make a block for an icon, because it can be part of anything, not just buttons.
secondly, we kind of agreed yesterday :))
.b{
// желательно использовать для общих стилей
}
b--m{
// желательно использовать для внешнего вида.
}
.b__e{
// желательно использовать для позиционирования.
}
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question