title: C# how to set const property value from appsettings.json
body: <p>I have a simple class in C# with few const properties. It is having hardcoded values right now. I had to make it dynamic so the values can be read from appsetting.json or please suggest me if any other better way.</p>
  <pre><code>public sealed class DebugConst
  {
      public const string IndicatorName = &quot;Indicator&quot;;
  }
  </code></pre>
  <p>This const value is used in another class file as.</p>
  <pre><code>if (xx == DebugConst.IndicatorName  )
  {
  }
  </code></pre>
  <p>appsettings.json:</p>
  <pre><code>&quot;DebugConst&quot;: {
  &quot;IndicatorName&quot;:&quot;New Indicator&quot;
  }
  </code></pre>
  <p>As this is a simple class I can't use dependency injection where I can configure the section in Startup. ConfigureServies()</p>
  <p>Can anyone suggest a better way to achieve this?</p>
  <p>Thanks</p>