title: Using the HTML 5 DatePicker with the Date input field
body: <p>I am trying to learn more about HTML5 dates.  I have added the following code to an MVC Core 2.1 view:</p>
  
  <pre><code>&lt;label asp-for="DOB" class="control-label"&gt;&lt;/label&gt;
  
  @{ 
      var minDate = DateTime.Now.AddYears(-99).Date;
      var maxDate = DateTime.Now.AddYears(-18).Date;
      var defaultDate = DateTime.Now.AddYears(-25).Date;
  }
  
  &lt;input asp-for="DOB" class="datefield" type="date" min=@minDate max=@maxDate value=@defaultDate/&gt;
  &lt;span asp-validation-for="DOB" class="text-danger"&gt;&lt;/span&gt;
  </code></pre>
  
  <p>The HTML rendered looks like this:</p>
  
  <pre><code>&lt;input class="datefield" type="date" min="23/10/1919 00:00:00" max="23/10/2000 00:00:00" value="23/10/1993 00:00:00" data-val="true" data-val-required="The DOB field is required." id="DOB" name="DOB" /&gt;
  </code></pre>
  
  <p>I have a few questions:</p>
  
  <p>1) The default value of the date does not appear i.e. it says: dd/mm/yy.  If I change my MVC code to this then it does work:</p>
  
  <pre><code>&lt;input asp-for="DOB" class="datefield" type="date" min=@minDate max=@maxDate value="1900-01-01"/&gt;
  </code></pre>
  
  <p>Why is it not accepting the variable specifically for the default value?</p>
  
  <p>2) Are there any implications of changing the class to: datefield (from: form-control) in the MVC view.</p>
  
  <p>3) Is it possible to specify a default date for the calendar, without the value appearing in the input field?</p>