FREE Web Template Download
HTML CSS JAVASCRIPT SQL PHP BOOTSTRAP JQUERY ANGULARJS TUTORIALS REFERENCES EXAMPLES Blog
 

AnimationEvent animationName Property

Event Object Reference Event Object

Example

Get the animation name associated with an animation:

var x = document.getElementById("myDIV");
x.addEventListener("animationstart", myStartFunction);

function myStartFunction(event) {
    this.innerHTML = "Animation-name is: " + event.animationName;
}
Try it Yourself »

Definition and Usage

The animationName property returns the name of the animation, when an animation event occurs.

The name of the animation is the value of the animation-name CSS property.

This property is read-only.


Browser Support

The numbers in the table specify the first browser version that fully supports the property.

Property
animationName Yes 10.0 6.0 Yes Yes

Syntax

event.animationName

Technical Details

Return Value: A String, representing the name of the animation

Related Pages

HTML DOM reference: The animationstart Event

HTML DOM reference: The animationiteration Event

HTML DOM reference: The animationend Event

HTML DOM reference: AnimationEvent elapsedTime Property

CSS reference: CSS3 animation Property

CSS reference: CSS3 animation-name Property


Event Object Reference Event Object