Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
Maintainable CSS
Search
Juanda Zapata
March 30, 2016
Programming
88
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Maintainable CSS
Introduction to BEM
Juanda Zapata
March 30, 2016
More Decks by Juanda Zapata
See All by Juanda Zapata
Principles of Visual Design
juanzuluaga
0
85
Adapter Pattern
juanzuluaga
0
180
Elixir 101 - The Erlang VM
juanzuluaga
5
340
UI Fundamentals for Programmers
juanzuluaga
0
320
UI fundamentals for programmers
juanzuluaga
0
400
Programming in paradise
juanzuluaga
1
150
Intro to Ruby
juanzuluaga
1
700
Other Decks in Programming
See All in Programming
AIで開発が速くなった先で、開発チームは何を目指すか
shihochan
1
1.7k
Agents on Rails - Rails at Scale 2026
irinanazarova
0
570
オーケストレーション記述言語 Katari
yukikurage
0
130
AmebaブログはKMPから卒業します
kmars0605
0
210
Augmenting AI with the Power of Jakarta EE
ivargrimstad
0
270
Lambda durable functionsでHuman in the Loopを楽に…楽に……
har1101
0
150
3回つくってわかった、 定期実行ジョブ基盤の本質情報
takai
0
580
Apple Intelligence を用いた個人情報誤送信防止、及びユーザーリクエスト体験の改善について
yukiny
0
360
自作Discord音声botをLambda MicroVMsに移行した話 / Migrating My Discord Voice Bot to Lambda MicroVMs
akihisaikeda
0
120
re:Inventに行く前に知っておきたい現地参加のノウハウ
nokomoro3
0
450
ChromeでローカルLLM
ryu1013
0
150
個人開発者よ、Honoを使え(おじさんver)
tanahiro2010
2
270
Featured
See All Featured
[RailsConf 2023] Rails as a piece of cake
palkan
59
7.1k
Google's AI Overviews - The New Search
badams
0
1.6k
Impact Scores and Hybrid Strategies: The future of link building
tamaranovitovic
0
460
Agile Actions for Facilitating Distributed Teams - ADO2019
mkilby
0
310
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
46
3k
The #1 spot is gone: here's how to win anyway
tamaranovitovic
4
1.2k
Public Speaking Without Barfing On Your Shoes - THAT 2023
reverentgeek
1
600
Build The Right Thing And Hit Your Dates
maggiecrowley
39
3.5k
A Soul's Torment
seathinner
8
3.8k
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
31
2.9k
Fashionably flexible responsive web design (full day workshop)
malarkey
409
67k
JAMstack: Web Apps at Ludicrous Speed - All Things Open 2022
reverentgeek
1
640
Transcript
Maintainable CSS with BEM
a set of conventions
not a library
not a framework
set of conventions
enforce them in code review
not a silver bullet
writing maintainable CSS is HARD
add everything to app.sass
app.sass => 1000 LOC
too hard to find a selector
too easy to overwrite a style
not maintainable
BEM
Block Element Modifier
None
None
None
None
None
None
not easily overwritten by accident
None
ugh that's a lot of typing
None
folder structure
again, not enforced by any script or framework
better to have several small focused files
None
None
use the power of SASS
variables
we can change the whole L&F of an app just
by modifying one file
None
alternatives
SMACSS https://smacss.com/
Scalable Modular Architecture for CSS
Used by TWTBS
Selectors tend to be deeply nested
Hard to customize
It's ok to mix BEM and SMACSS
CSSModules http://glenmaddern.com/articles/css-modules
Gaining a lot of steam in the REACT community
It's a step forward over BEM without global namespaces
thanks!
questions?