Manage objects creation and dependencies using a descriptive way. It's a simple approach to inversion of control.
It currently only supports constructor injection by order, not by name
Install
$ yarn add deepin
Usage
/* importing UserController, UserService & UserRepository... */ const injector = Injector /** * Create a brand new instance of the UserController * on each call */const userController = injector /** * Always retrieve the SAME instance of a UserController */const userController = injector
Shortcut usage for useClass :
/* importing UserController, UserService & UserRepository... */ const injector = Injector
See also
License
Copyright (c) 2017 Marvin Frachet
Licensed under the MIT license.