Skip to content

Glossary: Software Design Patterns in JavaScript

Constructor injection

Passing an object its dependencies as constructor arguments, to keep for its whole life. OrderLog receives its repo, clock and notifier this way.

Where the book teaches it

Related terms

Dependency injectionDependency