added support for DI for View