Created
May 15, 2015 23:13
-
-
Save luisrudge/e3752737755b8d33ec4f to your computer and use it in GitHub Desktop.
is this right according to BEM?
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<aside class="sidebar"> | |
<nav class="menu"> | |
<div class="menu-item"> | |
<a href="" class="menu-item__link"> | |
<span class="menu-item__icon"> | |
<i class="ion-ios-home-outline"></i> | |
</span> | |
<span class="menu-item__text"> | |
Home | |
</span> | |
</a> | |
</div> | |
</nav> | |
</aside> |
so I can go from an element (menu__item
) to a block again (menu-link
)?
@luisrudge absolutely, you just want to keep any nested blocks independent of their parents (i.e. reduce the depth of applicability). So you don't want styles from the menu
block leaking through to menu-item
.
awesome. Thanks!
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I'd tweak it a little bit...