angular-animate-change ![Build Status](https://camo.githubusercontent.com/b27f4d27e50011324f765a9386b992fe60effbb21a065752357282dda547ab68/68747470733a2f2f7472617669732d63692e6f72672f62656e647275636b65722f616e67756c61722d616e696d6174652d6368616e67652e7376673f6272616e63683d6d6173746572)
Angular directive for applying an animation class to an element whenever a value changes. Useful for applying attention-calling animation like flashes or shakes.
Installing
# npm
$ npm install angular-animate-change
# bower
$ bower install angular-animate-change
Setup
// node module exports the string 'animate-change' for convenience
angular.module('myApp', [
require('angular-animate'),
require('angular-animate-change')
]);
// otherwise, include the code first then the module name
angular.module('myApp', [
'ngAnimate',
'animate-change'
]);
API
animateChange
(directive)
<span animate-change="value" change-class="flash"></span>
When $scope.value
changes, the class 'flash'
will be added. Animation classes will applied during the transition.