Angular Animation events

Sami C.
1 min readFeb 27, 2019

--

Today I had a situation where I had to execute an event after an animation was finished, I wasn’t really sure how to do it, so after some digging I found that Angular provides events for your animation.

The $event is of type AnimationEvent. There are 2 events, start and done. Simple as that you can use them to execute some logic before the animation or after the animation ends.

More information can be found at https://angular.io/api/animations/AnimationEvent#animationevent

Happy coding!

--

--

Sami C.
Sami C.

Written by Sami C.

Freelance Software Engineer

No responses yet