Rahul
Rahul

Reputation: 47086

ng-repeat: adding a new element with an effect

Currently I am using ng-repeat to show a division.

<div class="something" ng-repeat="item in items">{{item.name}}</div>

In my controller the moment I add one more item to items it shows in my page. But it just displays the new content. What I want is to show an effect while its added like the new div should slide down while being added to the page. How I can I achieve it?

Upvotes: 1

Views: 3013

Answers (1)

dazzle
dazzle

Reputation: 1346

Try adding a ngAnimate attribute with animation values. You can find more information here http://www.yearofmoo.com/2013/04/animation-in-angularjs.html#animating-ng-repeat

Upvotes: 1

Related Questions