2 ms·
He has a point. For most uses I see of DI, a service locator would have been better. I think that some framework got too far with DI, especially those where a
by LoSboccacc 12y ago
He has a point. For most uses I see of DI, a service locator would have been better.
I think that some framework got too far with DI, especially those where a dependency is managed in a file which cannot be debugged or overloaded (i.e. spring with xml).
As long as DI is used to decouple services, that's seems fine to me. Decoupling object in the dm hover seems overkill - like in the sample, where the address is injected on the person class. That rarely makes sense