0Pricing
Frontend Academy · Lesson

BEM Methodology: Block Element Modifier

Name CSS classes with the Block__Element--Modifier pattern to create self-documenting, low-specificity, reusable component styles.

What Is BEM?

BEM (Block, Element, Modifier) is a CSS naming convention that makes styles predictable, reusable, and conflict-free. By encoding component structure in class names, it eliminates specificity wars and accidental style collisions.

Blocks — Standalone Components

A Block is an independent, reusable component: card, button, nav. The class name is the block name, written in lowercase with hyphens.

<div class="card">...</div>
<button class="btn">...</button>
<nav class="main-nav">...</nav>

All lessons in this course

  1. BEM Methodology: Block Element Modifier
  2. CSS Modules: Scoped Class Names
  3. CSS-in-JS: Styled-components and Emotion
  4. Tailwind CSS Utility-First Approach
← Back to Frontend Academy