Created
May 12, 2018 13:56
-
-
Save jesuscampos/60ff60bea7b136dde96eecc9d9f392eb to your computer and use it in GitHub Desktop.
Dependency Injection to be available in Startup constructor
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static IWebHost BuildWebHost(string[] args) => | |
WebHost.CreateDefaultBuilder(args) | |
.ConfigureServices(services => | |
services.AddScoped<IMyClass, MyClass>() | |
.UseStartup<Startup>() | |
.Build(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment