title: How to inject IConfiguration in asp.net core 6
body: <p>There is no Startup.cs in the web/api application any more.</p>
  <p>We used to be able to inject <code>IConfiguration</code> into that <code>Startup</code> class.</p>
  <pre><code>public class Startup
  {
      public Startup(IConfiguration configuration)
      {
          Configuration = configuration
      }
      ...
  }
  </code></pre>
  <p>Now that those add service and configuration code is moved into <strong>Program.cs</strong>, what is the correct way to access configuration from there?</p>