Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Utility CSS 2019
Search
Daniel Fosco
March 18, 2019
Design
0
86
Utility CSS 2019
Updated version of my presentation highlighting the advantages (and pitfalls) of utility-based CSS
Daniel Fosco
March 18, 2019
Tweet
Share
More Decks by Daniel Fosco
See All by Daniel Fosco
Let's talk about design portfolios
dfosco
3
110
UX Design – What, Why, How
dfosco
0
190
Portfolio Talk
dfosco
0
110
Utility CSS
dfosco
2
76
UX Design – Primeiros Passos
dfosco
1
120
CSS Modular — Boas Práticas e Bizus
dfosco
1
110
Other Decks in Design
See All in Design
Portfolio 齋藤明敏 Hiroyuki Saito_守秘義務あり
crearedesign
0
380
TWCP#21 UXデザインと哲学のはなし
shinn
0
220
【MIXI MEETUP!ー TECH & DESIGN DAYー】【工数98%削減】Xでモンストを話題にせよ!生成AIの活用で日本トレンド6位を獲得した企画の設計&デザイン術
mixi_design
PRO
0
180
越境するデザイン人材:デザイナーが社会資本となる世界へ
goodpatch
1
440
Emmy's Artwork
mcksmith
0
180
CursorでAI活用のナレッジベースを構築する
kanzaki
0
1.1k
「稼ぐ」だけでなく 「還す」ためのデザイン / Designship2025
culumu
1
530
mount_company_profile
mount_inc
0
4.2k
Shaolin_Showdown
solmetts
0
220
root COMPANY DECK / We are hiring!
root_recruit
1
25k
Figmaレクチャー会Part1 基本のき編@千株式会社 社内勉強会
designer_no_pon
0
180
Treasure_Hunting
solmetts
0
160
Featured
See All Featured
Site-Speed That Sticks
csswizardry
13
1k
svc-hook: hooking system calls on ARM64 by binary rewriting
retrage
1
36
Why Our Code Smells
bkeepers
PRO
340
58k
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
48
9.8k
Applied NLP in the Age of Generative AI
inesmontani
PRO
3
2k
Darren the Foodie - Storyboard
khoart
PRO
0
2k
For a Future-Friendly Web
brad_frost
180
10k
The Curse of the Amulet
leimatthew05
0
6.3k
Exploring the relationship between traditional SERPs and Gen AI search
raygrieselhuber
PRO
2
3.5k
Reflections from 52 weeks, 52 projects
jeffersonlam
355
21k
Data-driven link building: lessons from a $708K investment (BrightonSEO talk)
szymonslowik
1
860
The Pragmatic Product Professional
lauravandoore
37
7.1k
Transcript
UTILITY CSS
WHAT
WHAT HOW
WHAT HOW AND WHY
WHAT IS ATOMIC CSS FUNCTIONAL CSS
ATOMIC DESIGN BRAD FROST
None
None
.padding-small { padding: 15px; } .white { color: white }
.bg-blue { background-color: blue; }
None
None
.u-display-block { display: block } .u-display-inline { display: inline }
.u-display-inline-block { display: inline-block } .u-position-relative { position: relative }
None
None
None
None
None
None
REFACTOR ALL THE STYLES!
INSPIRATION TO MAKE OUR CSS MORE... CONSISTENT MANTAINABLE PERFORMANT
CONSISTENCY
None
None
GOOD DEFAULTS SENSIBLE SCALE
None
None
None
None
THE GOOD OPTIONS ARE YOUR ONLY OPTIONS
YOU DON'T WRITE CSS YOU JUST USE CSS
WRITE MARKUP
WRITE MARKUP → SAVE
WRITE MARKUP → SAVE → REFRESH
DEMO
MANTAINABILITY
None
FUNCTIONAL CSS FUNCTIONAL PROGRAMMING
PURE FUNCTIONS
FOR A GIVEN INPUT THE OUTPUT WILL ALWAYS BE THE
SAME
X × 2
2 × 2 → 4
2 × 2 → 4 3 × 2 → 6
2 × 2 → 4 3 × 2 → 6
2 × 2 → 5
.class { color: blue }
.another { color: red } .class { color: blue }
None
STYLES DON'T OVERWRITE EACH OTHER NO SIDE-EFFECTS
YOU DON'T NEED TO KEEP TRACK OF YOUR CSS
PERFORMANCE
The Problem with CSS
None
None
None
184
123
499
.db { display: block }
.fl { float: left }
None
WHAT DOES THIS MEAN IN REAL LIFE?
None
None
508KB TO 175KB 65% REDUCTION
IT CAN BE MADE EVEN SMALLER
m.booking.com
REFACTORING CSS HOLDS VERY LITTLE BUSINESS VALUE
How can we explore Atomic CSS to improve our user
experience and development process?
THANKS! !
bit.ly/functional-css-presentation