title: Angular Forms: How to avoid multiple NgIf divs for validation error messages?
body: <p>I would like to simplify the code below:</p>
  
  <pre class="lang-html prettyprint-override"><code>&lt;div *ngIf="form1.errors?.checkDate &amp;&amp; (form1.touched || form1.dirty)" class="cross-validation-error-message alert alert-danger"&gt;
      Date can't be in the future.
  &lt;/div&gt;
  &lt;div *ngIf="form1.errors?.notAfterDate &amp;&amp; (form1.touched || form1.dirty)" class="cross-validation-error-message alert alert-danger"&gt;
      Birth Date must be after 1/1/1800.
  &lt;/div&gt;
  </code></pre>
  
  <p>It should have only 1 <code>div *ngif</code> and pass the error message as a value instead of hardcoding or use a <code>ngFor</code>?</p>
  
  <p>Any help on this is much appreciated. Thanks.</p>