1 min readJul 24, 2019
Most of the no-trivial projects are composed of different modules/libraries. Imagine we apply the same DIC pattern in different libraries. The name conflict will become inevitable. Name “db” in different modules means completely different concepts. That’s why in a statically typed language, it’s a bit better, as Type is also part of the identifier. However, the global registry is always the source of fragility even with static types. There’s no easy way to do static check on the correctness of wiring.