Service locator in nodejs Service Locator is used when you don't know the actual provider of the service before runtime. Depenency Injection is used when you know it's the static container that provides that service. Development node index.js