ASP.NET Core Dependency Injection
| public IConfigurationRoot Configuration { get; } | |
| // This method gets called by the runtime. Use this method to add services to the container. | |
| public void ConfigureServices(IServiceCollection services) | |
| { | |
| // Add framework services. | |
| services.AddMvc(); | |
| services.AddSingleton(Configuration); | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment