Upgrade to PRO for Only $50/Year—Limited-Time Offer! 🔥
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Write S.O.L.I.D code
Search
Yoan
June 13, 2017
How-to & DIY
2
2.5k
Write S.O.L.I.D code
Learn how to write Object Oriented S.O.L.I.D code
Yoan
June 13, 2017
Tweet
Share
More Decks by Yoan
See All by Yoan
L'artisanat logiciel à l'heure du numérique responsable
thirion
0
49
Clean Code du point de vue de la cognition
thirion
0
160
Agile Tech Coaching - The Missing Piece Of Your Organization
thirion
1
110
Cultiver l'intelligence collective à l'heure de ChatGPT
thirion
0
130
Clean Code from the Cognition Point of View
thirion
2
170
Xanpan - une méthode agile hybride centrée sur l'équipe
thirion
0
190
Les aventures d'un facilitateur au pays des techs - Agile Grenoble 2023
thirion
0
130
Clean Code du point de vue de la cognition
thirion
1
250
Les aventures d'un facilitateur au pays des techs - Agile Tour Lausanne 2022
thirion
0
190
Other Decks in How-to & DIY
See All in How-to & DIY
個人制作コンテンツの多言語展開のノウハウを全公開! 〜世界に自分を発信しよう!〜
syotasasaki593876
0
120
RDKX3 ハンズオン資料 東京 D-Robotics 日本語
takasumasakazu
1
180
カンファレンスでリフレッシュ!無理なく楽しむカンファレンス参加術 / How to enjoy conferences without stress
kattsuuya
1
9.2k
2025年03月02日 メイカーズながおかまつり での講演 「コミュニティベースでの製品開発ものづくりフェアの役割」
takasumasakazu
0
280
バッドプラクティスから学ぶハワイアン航空で行く re:Invent
kentosuzuki
0
430
わたしと仕事とアジャイルコミュニティ / developers summit 2025
matsuoshi
0
1.5k
Node-REDで制御できるエッジカメラのreCameraを触る #iotlt #JLCPCB #recamera
n0bisuke2
0
130
自分がご機嫌になれる 素敵な場所を守るために
kenichirokimura
3
500
グローバルAWSユーザー コミュニティとJAWS-UG - JAWS FESTA 2024 in Hiroshima
awsjcpm
0
5k
目指せ!本を書いて夢の不労所得 #第3木曜LT会
kaitou
1
140
苦いビールを避ける冴えたやり方
watany
2
450
新婚19年目から学ぶ夫婦円満の正しい歩き方 / Life is beautiful
soudai
PRO
12
4.9k
Featured
See All Featured
Automating Front-end Workflow
addyosmani
1371
200k
The Language of Interfaces
destraynor
162
25k
[RailsConf 2023] Rails as a piece of cake
palkan
58
6.1k
Context Engineering - Making Every Token Count
addyosmani
9
470
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
234
17k
4 Signs Your Business is Dying
shpigford
186
22k
Side Projects
sachag
455
43k
Refactoring Trust on Your Teams (GOTO; Chicago 2020)
rmw
35
3.3k
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
31
2.6k
How Fast Is Fast Enough? [PerfNow 2025]
tammyeverts
3
380
How STYLIGHT went responsive
nonsquared
100
5.9k
A Tale of Four Properties
chriscoyier
162
23k
Transcript
@yot88 By yoan thirion S.O.L.I.D principles
@yot88 bad code / Good code Bad code vs Good
code Categorize each piece of code
None
@yot88 Singleton Tight Coupling Untestability Premature Optimization Indescriptive Naming Duplication
Single Responsibility Open/Closed Principle Liskov Substitution Interface Segregation Dependency Inversion Patterns and anti-patterns
@yot88 SRP A class should have only 1 responsibility
@yot88 Software entities should be open for extension, but closed
for modification. Open closed
@yot88 Subtypes must be substitutable for their base types. Liskov
substitution
@yot88 Clients should not be forced to depend on methods
that they do not use. Interface segregation
@yot88 High level modules should not depend on low level
modules : both should depend on abstractions. DI
@yot88 Good code / bad code Align each piece of
code with a S.O.L.I.D principle
1 3 3 1 3 16 13 2 4 14
15 6 8 9 12 5 10 11
3 13 16 1 3 16 13 2 4 14
15 6 8 9 12 5 10 11
3 4 2 1 3 16 13 2 4 14
15 6 8 9 12 5 10 11
3 15 14 1 3 16 13 2 4 14
15 6 8 9 12 5 10 11
3 8 6 1 3 16 13 2 4 14
15 6 8 9 12 5 10 11
3 11 9 1 3 16 13 2 4 14
15 6 8 9 12 5 10 11
3 10 5 1 3 16 13 2 4 14
15 6 8 9 12 5 10 11
12 1 3 16 13 2 4 14 15 6
8 9 12 5 10 11
1 3 16 13 2 4 14 15 6 8
9 12 5 10 11
@yot88 Let’s refactor using s.O.L.I.D
@yot88 exercises Practice S.O.L.I.D principles on code examples Clone the
repository at : https://github.com/ythirion/solid-kata Foreach code example : • identify why it’s breaking the given principle • Write down your refactoring strategy • Refactor it
@yot88 Where do you stand ? No quite yet On
the way Ready to roll