title: IConfiguration is always NULL .NET CORE in Blazor app / Razor
body: <p>IConfiguration is always null no matter what i try.. I have also tried to add singleton to the startup class, but always null...</p>
  <p>Startup class</p>
  <pre><code>        public Startup(IConfiguration configuration)
          {
              Configuration = configuration;
          }
  
          public IConfiguration Configuration { get; }
  </code></pre>
  <p>Here is my Security class</p>
  <pre><code>        IConfiguration _configuration { get;} **&lt;&lt;always null**
          public Security(IConfiguration configuration) **&lt;&lt;always null**
          {
              _configuration = configuration;
          }
           public  string GetConnectionString()
          {
              string connectionString = _configuration.GetConnectionString(&quot;localDb&quot;);
              return connectionString;
  
          }
  </code></pre>
  <p>Here is my Index.Razor page</p>
  <pre><code> namespace WebbiSkoolsQuizManager.Pages
  {
      public class IndexBase : ComponentBase
      {
          public IConfiguration Configuration { get; }
          public async Task TryLogin(string user, string pass)
          {
              
          }
         
           
  
          public async Task AddUserHash(string username, string password)
          {
              Security secure = new Security(Configuration);
              string connectionstring = secure.GetConnectionString();
              
              
          }
      }
  }
  </code></pre>
  <p>Appsettings.json</p>
  <pre><code>{
    &quot;Logging&quot;: {
      &quot;LogLevel&quot;: {
        &quot;Default&quot;: &quot;Information&quot;,
        &quot;Microsoft&quot;: &quot;Warning&quot;,
        &quot;Microsoft.Hosting.Lifetime&quot;: &quot;Information&quot;
      }
    },
    &quot;ConnectionKeys&quot;: {
      &quot;localDb&quot;: &quot;Data Source=(localdb)\\MSSQLLocalDB;Initial Catalog=Quiz;Integrated Security=True;Connect Timeout=30;Encrypt=False;TrustServerCertificate=False;ApplicationIntent=ReadWrite;MultiSubnetFailover=False&quot;
  
    },
    &quot;AllowedHosts&quot;: &quot;*&quot;
  }
  </code></pre>
  <p>Thank you in advance, i have searched high and low, regarding a fix for blazor specific but i cant find anything.. (P.S its .Net core 3)</p>