Skip to content

Glossary: Software Design Patterns in JavaScript

Service locator

A global registry that code reaches into for its dependencies. It looks tidy but hides dependencies and makes tests change the global, unlike injection.

Where the book teaches it

Related terms

Dependency injectionDI container