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
Using single property classes in CSS - FEL Nov ...
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Richard Bray
November 27, 2015
Technology
650
2
Share
Using single property classes in CSS - FEL Nov 2015
Richard Bray
November 27, 2015
More Decks by Richard Bray
See All by Richard Bray
Webpack Talk
richardbray
0
49
The benefits of Atomic CSS - London Sass Feb 2016
richardbray
4
260
Other Decks in Technology
See All in Technology
AIにより大幅に強化された AWS Transform Customを触ってみる
0air
0
280
Why we keep our community?
kawaguti
PRO
0
360
Blue/Green Deployment を用いた PostgreSQL のメジャーバージョンアップ
kkato1
1
230
契約書からの情報抽出を行うLLMのスループットを、バッチ処理を用いて最大40%改善した話
sansantech
PRO
3
340
QA組織のAI戦略とAIテスト設計システムAITASの実践
sansantech
PRO
1
310
I ran an automated simulation of fake news spread using OpenClaw.
zzzzico
1
410
Cursor Subagentsはいいぞ
yug1224
2
130
会社紹介資料 / Sansan Company Profile
sansan33
PRO
16
410k
LLMに何を任せ、何を任せないか
cap120
11
6.9k
Databricks Appsで実現する社内向けAIアプリ開発の効率化
r_miura
0
230
BFCacheを活用して無限スクロールのUX を改善した話
apple_yagi
0
140
Databricks Lakehouse Federationで 運用負荷ゼロのデータ連携
nek0128
0
110
Featured
See All Featured
Navigating Algorithm Shifts & AI Overviews - #SMXNext
aleyda
1
1.2k
Learning to Love Humans: Emotional Interface Design
aarron
275
41k
Taking LLMs out of the black box: A practical guide to human-in-the-loop distillation
inesmontani
PRO
3
2.1k
End of SEO as We Know It (SMX Advanced Version)
ipullrank
3
4.1k
VelocityConf: Rendering Performance Case Studies
addyosmani
333
25k
世界の人気アプリ100個を分析して見えたペイウォール設計の心得
akihiro_kokubo
PRO
68
38k
Writing Fast Ruby
sferik
630
63k
We Have a Design System, Now What?
morganepeng
55
8.1k
AI: The stuff that nobody shows you
jnunemaker
PRO
4
500
Public Speaking Without Barfing On Your Shoes - THAT 2023
reverentgeek
1
350
Leadership Guide Workshop - DevTernity 2021
reverentgeek
1
260
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
32
2.6k
Transcript
Using single property classes in CSS Richard Bray @ceiga
This is the first time I’ve ever done a talk
This is my first FEL event!
None
Why?
None
Who am I?
Developer / Designer / Product Designer
None
Side Projects - richbray.me
The Problem
CSS has become complicated
Before Write CSS Upload it. Done!
Now Preprocessor Normal Css Post Process Minify
Now Preprocessor Normal Css Post Process Minify
Now Preprocessor Normal Css Post Process Minify Server Side Language
Terminal Knowledge
Now Version Control (maybe)
None
Multiple files
What If?
None
Typical Process 1. Inspect Element in Chrome 2. Make change
in Developer Tools 3. Run site locally 4. Locate .scss file and change 5. Save and View 6. Go through process mentioned previously
Typical Process 1. Inspect Element in Chrome 2. Make change
in Developer Tools 3. Run site locally 4. Locate .scss file and change 5. Save and View 6. Go through process mentioned previously
New Process 1. Inspect Element in Chrome 2. Make change
in Developer Tools 3. Update and save html file
Not inline CSS
Helper (or single property) Classes
None
None
None
None
None
New Process 1. Inspect Element in Chrome 2. Make change
in Developer Tools 3. Update and save html file
How do you implement this?
Either
Or visit richbray.me/bricks
None
None
None
Similar naming convention
Or visit richbray.me/bricks
New projects only! (unless you’re refactoring)
Let your HTML do the work
Another Thing
Not a fan of @extends
None
None
Use @mixins instead
3 issues with this method
1. Lots of classes on a html element looks ‘ugly’
None
None
None
2. Slight chance of bloating your CSS
None
None
You Could
Or Just leave it 2 KB compressed 82.34 KB compressed
3. Media queries is tough
None
Desktop Mobile
None
This isn’t a new concept
None
None
None
None
http://ux.mailchimp.com/patterns/helpers
http://ux.mailchimp.com/patterns/helpers
Thank You! Richard Bray @Ceiga https://github.com/RichardBray
http://digitalcroydon.net/event/