Skip to content

Instantly share code, notes, and snippets.

@ankitvijay
Created March 16, 2020 20:24
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ankitvijay/89fd6fe6018d133780d81823f945e1aa to your computer and use it in GitHub Desktop.
Save ankitvijay/89fd6fe6018d133780d81823f945e1aa to your computer and use it in GitHub Desktop.
Captive Dependency 4
public class Program
{
public static void Main(string[] args)
{
CreateHostBuilder(args).Build().Run();
}
public static IHostBuilder CreateHostBuilder(string[] args) =>
Host.CreateDefaultBuilder(args)
.ConfigureWebHostDefaults(webBuilder =>
{
webBuilder.UseStartup<Startup>();
})
.UseDefaultServiceProvider((env, c) =>
{
if (env.HostingEnvironment.IsDevelopment())
{
c.ValidateScopes = true;
}
});
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment