UNPKG

tlojs

Version:

The Last One - The last npm package you'll need to install

20 lines (14 loc) 221 B
# Dependency Injection for Typescript ## Usage ```typescript @Injectable() class A { getNumber() { return 1 } } @Injectable() class B { constructor(public a: A) { } } const service = Injector.resolve<B>(B) ```