ngFormGroup applies Bootstrap validation classes based on
In your Angular project, run
bower install --save ng-form-group to save the
module. Then, in your HTML, add:
And lastly, in your Angular module, include
ng-form-group as a dependency:
Just mark up your form as recommended by Bootstrap
and any fields with the class
form-group will be automatically validated!
Now, when your model is invalided, by someone entering an invalid email
has-error class will be added to your form-group.
If you want to disable feedback for a specific form, add the
class to the form-group:
Bonus round: Feedback icons!
Just add the
class to your form group, and we'll automatically add bootstrap style Feedback
icons to your form fields.
To get your dev environment up and running, run
npm install and
to get the components we need.
Tests are run with
npm run test and you can build the minified source with
npm run build.
Releases are built using
npm run release:[type]. So, to generate a new patch
npm run release:patch. This script will:
- Generate minified, concatenated JS files,
- Increment the version in
- Tag a new release