Leaner Dependency Injection pattern in TypeScript

From Java style OOP to a more… TypeScripty feel ?

Elias Nygren
ITNEXT
Published in
3 min readAug 12, 2021

--

When does a coffee image not work in a programming article ?

Decoupling code, eliminating implicit dependencies, enabling testability is all great and Dependency Injection is the pattern for doing this. However, the traditional DI approach with class instances taking interfaces for other class instances is a bit too… Java? OOP? Enterprisy? Surely we can get…

--

--

Writer for

I’ve been a startup founder (CTO/CEO), freelancer, software engineer and a manager. Previously at Swappie, Europe’s fastest growing scaleup.