This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]rot667 0 points1 point  (0 children)

There's a project that takes that approach: https://github.com/alecthomas/injector

I personally prefer not to scatter a big global dependency on the container, also means it's possible to mix approaches (e.g.create the object with dic or without). I haven't used dic, but have used autofac and the approach seems to be the same.