Animate (easeOutCirc) a DOM Element using AngularJS

262 views Asked by At

How can I write this piece of the code in AnguarJs ?

Particularly the animation part (easeOutCirc) used in this example:

$(document).ready(function () { function addCircle() { var $circle = $('<div class="circle"></div>'); $circle.animate({ 'width': '300px', 'height': '300px', 'margin-top': '-150px', 'margin-left': '-150px', 'opacity': '0' }, 4000, 'easeOutCirc'); $('body').append($circle); setTimeout(function __remove() { $circle.remove(); }, 4000); } addCircle(); setInterval(addCircle, 1200); });

http://jsfiddle.net/Y3r36/311/

1

There are 1 answers

0
antimatter On

I think you could use something like this? https://docs.angularjs.org/api/ngAnimate