Skip to content

Instantly share code, notes, and snippets.

@sulco
Created March 12, 2016 22:33
Show Gist options
  • Select an option

  • Save sulco/41a19b5be77af3a2cd30 to your computer and use it in GitHub Desktop.

Select an option

Save sulco/41a19b5be77af3a2cd30 to your computer and use it in GitHub Desktop.
<div ng-app="app">
<form name="aForm" novalidate>
<label for="name">Your email</label>
<input type="email" id="name" ng-model="name" name="aField" required>
<ng-messages for="aForm.aField.$error">
<ng-message when="required">This field is required</ng-message>
<ng-message when="email">Please enter proper email address</ng-message>
</ng-messages>
<button ng-click="save()">Send</button>
</form>
</div>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment