<div ng-controller="FormController">
<form ng-submit="submitForm()">
<label>Name:</label>
<input type="text" ng-model="user.name" required>
<br>
<label>Email:</label>
<input type="email" ng-model="user.email" required>
<br>
<button type="submit">Submit</button>
</form>
</div>
ng-submit
: Binds an expression to the form’s submit event.ng-model
: Binds the input field to the model (in this case, user.name
and user.email
).