As you know, there are user-generated events like
onTouchStart, etc. You can listen to them to trigger an action.
But animations also emit events. They can signal when an animation started, stopped, or ran until the end.
Animation events are emitted both by the layer that’s being animated and by the Animation object. You can listen to either one.