you a default approach for new projects. • Thinking in Blocks, Elements and Modifiers helps you figure out what your design is made of. • BEM helps you getting started coding CSS a little bit quicker through a standard syntax.
hell in CSS specificty • Complex CSS selectors get a higher importance. You have to match up to this selector or use !important to override it. • Or find the actual CSS you want to change. But the bigger the CSS code base, the nastier that can get ;) Using single CSS classnames makes it easier to rework your existing CSS code base.
CSS reset/normalize not needed (preferably) • Remember BEM Blocks should be independent and reuseable. A global CSS reset/normalize does not exactly fit that idea. Perhaps use something like uncss in your build process to get only the needed normalize/reset CSS into your Blocks and Elements.
HTML/CSS decoupling • Using HTML element names in your CSS selectors forces you to update both when only one changes. • Using just single CSS BEM classnames makes them more portable to another HTML structure and markup.
CSS classnames • True.. No way around that. BEM can produce a very long and ugly classname that ruin you beautiful HTML markup. • But luckily, the visitor of the website will not look in the source too often. Unless they know what they’re doing ;)
teams for larger projects? • BEM CSS certainly has extra benefit in larger teams because of the meaningful CSS classname. • But working solo or for a small project you can also use the Block, Element and Modifier approach on a design to get started prototyping sooner.
will: • Set the standard for code quality across a codebase; • Promote consistency across codebases; • Give developers a feeling of familiarity across codebases; • Reuseable on any and all types of project; • Increase productivity;