DEV Community

Discussion on: 8 Ultimate Full Stack Interview Questions and Answers

Collapse
 
okolbay profile image
andrew

“You have inverted control by handing the responsibility of instantiating“

Its not in wikipedia definition of IoC, but by just letting framework wire-up code you haven’t inversed control too much. You can inject mock in unit tests now, but specific implementation (maybe from a different package) is still there. What I see as IoC is when you declare interface in module you want to be in control of the contact.