DEV Community

Discussion on: Solid. Is It Still Useful In 2021?

Collapse
 
phantas0s profile image
Matthieu Cneude

So:

  1. SRP: why only one purpose? It comes from more important principles information hiding and modules like decomposition, cohesion, and coupling.
  2. Open / Closed: this one is useless. It's from Bertrand Meyer and it only concerns inheritance, not interface implementation.
  3. Liskov Substitution Principle: this is from a paper by Barbary Liskov, and what she's saying is not what Martin (the one who came with the SOLID principle) is saying.
  4. Interface segregation: this is SRP applied to interfaces. It's not a principle.
  5. Dependency inversion principle: this one is quite useful.