search
profile img

Bharat Dwarkani

Sep 21, 2019
bookmarks

linkshazwazza.com

In many cases, you’ll want to ship MVC controllers, possibly views or tag helpers, etc… as part of your class library. To do this correctly you’ll want to add your assembly to ASP.NET’s “Application Parts” on startup. Its quite simple to do but you might want to make sure you are not enabling all sorts of services that the user of your library doesn’t need.

share
favorite_border0 visibility0
favorite_border0 visibility0 share
bookmarks
profile img

Bharat Dwarkani

Sep 15, 2019
bookmarks

linkfmoralesdev.com

DI will help us to simplify the management of all our dependencies. Services are registered in the net core container specifically in the Startup class. The container is responsible for creating and disposing of all service instances or in other words, it’s responsible for the life-time of all services registering in.

share
favorite_border0 visibility1
favorite_border0 visibility1 share
bookmarks
profile img

Bharat Dwarkani

Aug 30, 2019
bookmarks

linkanthonygiretti.com

You have probably wondered whether it is possible to manipulate different instances of the same service according to a certain context in your application. Well, know that it is possible. I have prepared in this article a concrete example of dynamic dependency injection in a multitenant WebAPI context: for the same service (interface) it is possible to invoke the concrete instance appropriate for the current tenant.

share
favorite_border0 visibility2
favorite_border0 visibility2 share
bookmarks
profile img

Bharat Dwarkani

Aug 18, 2019
bookmarks

linkgunnarpeipman.com

We all probably know how to inject an instance of the interface to the class using dependency injection in ASP.NET Core. But how can we inject all instances of the interface to some class, let’s say, controller, using dependency injection? The trick is simple and it’s shown in this blog post.

share
favorite_border0 visibility3
favorite_border0 visibility3 share
bookmarks
add