A
A
Alexey Nikolaev2017-02-04 20:29:42
css
Alexey Nikolaev, 2017-02-04 20:29:42

Is it possible to give two or more elements to one tag in BEM?

Good evening.
Is it possible in BEM to make one tag be represented by several elements at the same time? This is useful when you need to split the concept of "element" into two (select any property that does not fall under the concept of "modifier"). In other words, is it possible?

<div class="block">
    <div class="block__wrapper block__wrapper-outer">
        <div class="block__wrapper block__wrapper-inner"></div>
    </div>
</div>

Thanks in advance.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
O
Oleg, 2017-02-04
@Heian

Yes, you can mix BEM entities on one house element in any quantity.

I
iBird Rose, 2017-02-04
@iiiBird

This is useful when you need to split the concept of "element" into two (select any property that does not fall under the concept of "modifier").

in such cases it is easier to refer to the element from the parent. rather than produce 2 classes for the parent and child.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question