Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
    Vsevolod Strukchinsky
    @floatdrop
    This message was deleted
    Vsevolod Strukchinsky
    @floatdrop
    what do you think about amcss - http://glenmaddern.com/articles/introducing-am-css ?
    Alexander Savin
    @apsavin

    "The single-class pattern says yes, it feels simpler and avoids the case where someone forgets to include btn"

    Is anyone still writing css classes manually?..)
    If seriously, IMO it's very strange to use data attributes (others are not valid) for styling.

    Sergey Berezhnoy
    @veged
    amcss from bem point of view — just another way to write raw html
    it's easy to make basic bemhtml templates to serialise bemtjson in such manner
    but I can't see any strong reasons to make this
    Vsevolod Strukchinsky
    @floatdrop
    Vsevolod Strukchinsky
    @floatdrop
    Up and go getbem.com — we updated Introduction, Naming and Building.
    If you have any hints or find typos - let us know.
    Yelena Jetpyspayeva
    @mursya
    Anyone from CIS countries willing to bem hack? Here we go with our Hackathon https://tech.yandex.ru/events/bemup/15-november-2014/ Nov 15-16
    Alexej Yaroshevich
    @zxqfox
    Hey there. I've trying to port BH lib to PHP. Some help with tests will be appreciated! https://github.com/zxqfox/php-bem-bh :heart:
    Yelena Jetpyspayeva
    @mursya
    @zxqfox sure more BEM PHP guys are ut there in a forum too ;) pls, post there as well! thanks!!!
    Alexej Yaroshevich
    @zxqfox
    @mursya I want to finish up tests before wide publishing. And sure I'll post a message on forum when it'll be done.
    Yelena Jetpyspayeva
    @mursya
    Ребята, помогите команде Инны с ответами на вопросы http://bit.ly/bem-doc-ask
    sorry, wrong room
    Yelena Jetpyspayeva
    @mursya
    Guys, we fixed what we could for bem.info mobile. Its not the last version but better what we had before. Check update status at http://bit.ly/beminfo-mob-en Comments and ideas are welcome!
    Alexej Yaroshevich
    @zxqfox
    @mursya Great news!
    Vladimir Grinenko
    @tadatuta
    We did it! First #yahackathon on BEM in Moscow — it was more than awesome!
    We'll share details the next week and for now here are some photos: http://bit.ly/bem-hack-photo
    Ivan Voischev
    @voischev
    :+1:
    Alexej Yaroshevich
    @zxqfox
    Yelena Jetpyspayeva
    @mursya
    @zxqfox soooo awesome!!!!!!!!!!!!!
    Tim Navrotskyy
    @dypsilon
    How many developers are working at Yandex right now? (need this for my BEM presentation)
    Alexej Yaroshevich
    @zxqfox
    I'm not
    Tim Navrotskyy
    @dypsilon
    zxqfox, thanks, I'll note that in my presentation
    Alexej Yaroshevich
    @zxqfox
    Thanks. :palm_tree:
    Alexej Yaroshevich
    @zxqfox
    Russian wiki says it's 6000 employees. English — 5514 at Sept '14
    Tim Navrotskyy
    @dypsilon
    Yep, thanks. Would be nice to know how many of those people are working with BEM...
    Yelena Jetpyspayeva
    @mursya
    @dypsilon would be great to see slides.. now after the meetup, but next time beforehand would be handy. therefore we might have helped you better
    @dypsilon we also have http://bem.info/events/campjs-melbourne-2014/ to promote talks and http://bem.info/talks/campjs-melbourne-2014/ to advertise videos. so, would be happy to publish once its ready
    Tim Navrotskyy
    @dypsilon
    @mursya the meetup had an audience of only ~20 devs, so no big deal actually. Here are the slides: http://goo.gl/Wgd1Bs would be great if you could take a look and point out any mistakes before publishing. Feel free to contact me via email (see PM). I also speak russian.
    Alexej Yaroshevich
    @zxqfox

    @dypsilon ENB is not so much faster, maybe 1.2x. But with configuration in one file and another tech format.
    There are other libraries like bem-grid/bem-content/etc.

    Nice bad parts list! :palm_tree: Some points can be easily solved.

    Tim Navrotskyy
    @dypsilon
    @zxqfox thanks for the info, fixed it.
    Yelena Jetpyspayeva
    @mursya
    First #b_ #hackathon and first results — our doc team leaded by Inna Belaya http://bit.ly/bem-doc-report-en
    codercube
    @codercube
    hi, can @anyone please advise a good example of BEM approach with source files?
    Dima Belitsky
    @dab
    @codercube hi here. you can check our full-stack demo project — Social Services Search Robot (SSSR) — https://github.com/bem/sssr/
    Latest version with ENB builder and latest libs — https://github.com/bem/sssr/tree/cocaine
    codercube
    @codercube
    @dab thanks!
    Eric-Xu
    @Eric-Xu

    Hi @all. I'm having some trouble understanding how to define an element's scope using BEM and would be grateful for any help.
    I understand the principle of this naming convention:

    <ul class="menu">
      <li class="menu__item">
        <a class="menu__link">
          <span class="menu__text"></span>
        </a>
      </li>
    </ul>
    
    .menu {}
    .menu__item {}
    .menu__link {}
    .menu__text {}

    However, what happens when there are two sections, each with a menu block that needs to be styled differently?

    <section class="primary">
      <ul class="menu">
        <li class="menu__item">
          <a class="menu__link">
            <span class="menu__text"></span>
          </a>
        </li>
      </ul>
    </section>
    
    <section class="secondary">
      <ul class="menu">
        <li class="menu__item">
          <a class="menu__link">
            <span class="menu__text"></span>
          </a>
        </li>
      </ul>
    </section>

    Do we then end up with something like this?

    .menu--primary {}
    .menu--primary__item {}

    Thanks for any help.

    Anton Winogradov
    @awinogradov
    Hi! .menu.menu_primary .menu__item is right for you;)
    Eric-Xu
    @Eric-Xu
    @verybigman if I wanted to avoid any CSS nesting, would we then use .menu__item.menu_primary__item?
    Anton Winogradov
    @awinogradov
    No, you can mix block with mod on element or element of block, but don't mix modifier from block. This is don't right. You can read more about naming on bem.info/methodology.
    You can use modifier for element, ex: menu__item.menu__item_primary
    Eric-Xu
    @Eric-Xu

    Sorry, @verybigman. I'm a bit confused by this. Can you flush it out with an example?

    No, you can mix block with mod on element or element of block, but don't mix modifier from block.

    Alexej Yaroshevich
    @zxqfox
    He means that .block--modifier__element is impossible thing, It's .block__element but inside .block with .block--modifier.
    Eric-Xu
    @Eric-Xu
    Thanks for pointing that out @zxqfox. I did not know that .block--modifier__element is non-BEM compliant.
    But going back to @verybigman's example of menu__item.menu__item_primary, this to me, reads semantically like targeting the primary item element of the menu block.
    What if I wanted to target the item element of a primary menu block, given two types of menu blocks?
    Alexej Yaroshevich
    @zxqfox
    There is a npm package https://github.com/bem/bem-naming with helpers and simple API to parse/stringify
    @Eric-Xu Yes, you're right. And actually, It's a situation for cascade
    Cascades possible if they applied to elements by block's modifier. You don't brake anything with it even if you use your block with cascade in another project. Why you don't want to use it here? .block--modifier .block__element
    Eric-Xu
    @Eric-Xu
    @zxqfox We are experimenting with avoiding (unnecessary) nesting of selectors in our stylesheets. How common is it to find projects using BEM that also nests selectors? Was BEM created with nested selectors in mind?
    Alexej Yaroshevich
    @zxqfox
    @Eric-Xu Afaik BEM recommends to avoid unnecessary cascades to make blocks separate. Using them for changing view or behaviour of elements inside block if block have some modifier isn't unnecessary. It's logically right and actually one of the common cases to use cascade. That's why @verybigman said about .menu_primary .menu__item right after your first question. I don't really know why we shouldn't use cascades even if the task need cascade. But I'm agree that we should avoid nesting, linking different blocks in css selectors, etc. We should keep blocks separate to make them useful. In other way there is no chance that we can use that blocks once again.