-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Closed
Labels
IoC/Context@loopback/context: Dependency Injection, Inversion of Control@loopback/context: Dependency Injection, Inversion of Controlfeature
Description
See https://github.com/strongloop/loopback-next/pull/61/files#r102336527
We need to make it easy to know the input and output of the ctx's APIs. Here are some examples
// Hard to remember the string, easy to introduce typos
ctx.bind('someLongStringHere').to(SomeType);
// Does MyConcreteType implement MyInterface ???
// would be nice if the compiler checked this for me
ctx.bind('MyInterface').to(MyConcreteType);
// when I refactor code - I don't want to have to go find/replace all instances of 'someString'
ctx.bind('someString').to(SomeValue);Metadata
Metadata
Assignees
Labels
IoC/Context@loopback/context: Dependency Injection, Inversion of Control@loopback/context: Dependency Injection, Inversion of Controlfeature