docs($animate): require ngAnimate in example, syntax fixes

The example in the section "JavaScript-defined Animations" would not run without the ngAnimate dependency. Also added a missing comma and semicolons.
This commit is contained in:
Blaise Kal 2013-12-02 10:44:27 +01:00 committed by Matias Niemelä
parent 1a8d3c8b3a
commit d0f8bd30a6

View file

@ -190,7 +190,7 @@
*
* <pre>
* //!annotate="YourApp" Your AngularJS Module|Replace this or ngModule with the module that you used to define your application.
* var ngModule = angular.module('YourApp', []);
* var ngModule = angular.module('YourApp', ['ngAnimate']);
* ngModule.animation('.my-crazy-animation', function() {
* return {
* enter: function(element, done) {
@ -199,8 +199,8 @@
* //this (optional) function will be called when the animation
* //completes or when the animation is cancelled (the cancelled
* //flag will be set to true if cancelled).
* }
* }
* };
* },
* leave: function(element, done) { },
* move: function(element, done) { },
*
@ -215,7 +215,7 @@
*
* //animation that can be triggered after the class is removed
* removeClass: function(element, className, done) { }
* }
* };
* });
* </pre>
*