Style animationDirection Property
Style animationDirection Property
The animationDirection property is used to either set or return whether the animation should play in reverse on alternate cycles or not. It will not have any effect if the animation is set to play only once.
Syntax:-
Its syntax is:- object.style.animationDirection OR object.style.animationDirection = normal|reverse|alternate|alternate-reverse|initial|inherit
Return:-
Its return is:- string having animation-direction property of an element
Further Explanation:-
Value | Description |
---|---|
normal | The animation should play as normal |
reverse | The animation should play in reverse direction |
alternate | The animation will be played as normal every odd time and in reverse direction every even time. |
alternate-reverse | The animation will be played in a reverse direction every odd time and in a normal direction every even time. |
initial | Sets this property to its default value. |
inherit | Inherits this property from its parent element. |