Answer the question
In order to leave comments, you need to log in
Is it allowed in BEM for a block with a modifier to use a cascade for elements?
I have a block .products-item , it has elements .products-item__footer , .products-item__price , .products-item__info .
For which their styles are described.
There is a .products-item--lg modifier that doubles the width of the block and I need to modify some styles for the elements as well.
Is it permissible to use in this case a cascade like:
.products-item--lg .products-item__footer {}
.products-item--lg .products-item__price{}
.products-item--lg .products-item__info{}
Answer the question
In order to leave comments, you need to log in
Yes, it's allowed. And here is the actual comment on this issue from the latest BEMap https://youtu.be/sX8xQrwk6ko?t=45m30s
This is one of the killerfitch bam, when changing the modifier of the block, you can change its elements.
Thus, for example, topics are made for a block, or a state
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question