Skip to content

Instantly share code, notes, and snippets.

@crgrieve
Last active September 3, 2021 22:14
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 crgrieve/730e0b05b8800295831b0cad2c030475 to your computer and use it in GitHub Desktop.
Save crgrieve/730e0b05b8800295831b0cad2c030475 to your computer and use it in GitHub Desktop.
C#10 filescoped namespace
namespace Umbracov9DotNet6;
public class Program
{
public static void Main(string[] args)
=> CreateHostBuilder(args)
.Build()
.Run();
public static IHostBuilder CreateHostBuilder(string[] args) =>
Host.CreateDefaultBuilder(args)
.ConfigureLogging(x => x.ClearProviders())
.ConfigureWebHostDefaults(webBuilder => webBuilder.UseStartup<Startup>());
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment