I finally managed to make Angular 5 BrowserAnimationsModule work on my app.
Now I need to find a way to loop the animation infinitely.
How can I do this?
How can I make it repeat the same animation after a certain period of time?
I don’t know about an example, but you could just have Observable.interval fire every 3 seconds (or whatever) and whenever it fires, you reset your animation to the starting state. You probably would have to call ChangeDetectorRef.detectChanges() so Angular knew it happened, that’s the only wrinkle I can think of.
I’m trying to trigger a series of animation with a click of button.
So once you click on a button it should affect several div’s styles with different time transition.
Is there a way to add CSS animation class with a button click?
Oh yes… maybe that’s a possibility!
[ngClass] can add or remove CSS class but how can I make a button affect many other divs ? with different transition time?
I am looking for such a solution where animation is working continuously without help of any checkbox like in your case, like for example in your case if box and circle are replacing each other after some interval until boxClass is been removed, please provide me such a solution if possible??