Subtypes Must Replace Conditionals @ChristopherOkhravi
Subtypes Must Replace Conditionals  @ChristopherOkhravi
Uploaded August 2024 | Updated November 2026, 5 days ago
Subtype polymorphism should only be used when we can replace a conditional with behaviorally different branches. Why?
Subtypes Must Replace ConditionalsComposite Pattern DefinitionHigh Level Iterators replace Foreach | Code Walks 035Works VS ValuableRules Have Reasons (Always Ask Why)Reactive Programming from Scratch (JavaScript) - Ep3Impossible Is BetterDifferent algorithms or different values?Refactoring Attacks (by replacing conditionals with polymorphism)Depend on Abstractions not Concretions (Framework)Abstractions Should Reduce ComplexityAlways Use Interfaces
Christopher Okhravi |

Subtypes Must Replace Conditionals

SHARE TO X SHARE TO REDDIT SHARE TO FACEBOOK WALLPAPER