Discussion about this post

User's avatar
Jaime López's avatar

I would say that all SOLID principles are involved in IoC. Interfaces are involved and Classes as well so, Liskov Substitution and Interface Segregation principles must be used here. You also mentioned Single Responsibility and Dependency Injection principles as well. And finally, Open-Closed principle due to the behaviour of the main class that can change because of the classes injected in the constructor (or in a different way).

From my perspective, to understand IoC you should well understand or master SOLID principles. And this comes from practice, and practice, and practice. Newbie coders will have to spend time coding and realizing how this works. But it's worth it because of souch time they will save in the future.

Great article!!!

Expand full comment
1 more comment...

No posts