title: Html.GetEnumSelectList - Getting Enum values with spaces
body: <p>I was using <code>asp-items="@Html.GetEnumSelectList(typeof(Salary))"</code> in my Razor view with a select tag, to populate the list values based on the <code>enum Salary</code>.</p>
  
  <p>However, my enum contains some items which I would like to have spaces within. E.g. one of the items is <code>PaidMonthly</code>, but when I display this using <code>Html.GetEnumSelectList</code>, I would like it to be displayed as <code>"Paid Monthly"</code> (with a space in it)</p>
  
  <p>I tried using the <code>Description</code> attribute over each member in the enum, however when the select box renders it uses the raw value only.</p>
  
  <p>Can anyone please help me out with this matter?</p>
  
  <p>(My Code sample) -> Using ASP.NET Core 1.0</p>
  
  <p>Razor View:</p>
  
  <pre><code>&lt;select asp-for="PersonSalary" asp-items="@Html.GetEnumSelectList(typeof(Enums.Salary))"&gt;
  &lt;/select&gt;
  </code></pre>
  
  <p>Enum Salary:</p>
  
  <pre><code>public enum Salary
  {
      [Description("Paid Monthly")]
      PaidMonthly = 1,
      PaidYearly = 2
  } 
  </code></pre>