email&quot;&gt;This field must be a valid email address.&lt;/div&gt;
    &lt;div ng-message=&quot;maxlength&quot;&gt;This field can be at most 15 characters long.&lt;/div&gt;
  &lt;/div&gt;
&lt;/form&gt;
</code></pre>
<p>In order to show error messages corresponding to <code>myField</code> we first create an element with an <code>ngMessages</code> attribute
set to the <code>$error</code> object owned by the <code>myField</code> input in our <code>myForm</code> form.</p>
<p>Within this element we then create