HTML Style Animation Property | HTML Style Animation | HTML Animation Tutorial By WDH

HTML Style Animation Property


Style Objects

Examples

Use shorthand property change <div> element of animation:

document.getElementById("myDIV").style.animation="mymove 5s infinite";


try it"


Definition and Usage

animation property is a shorthand property animation six attributes:

animationName
animationDuration
animationTimingFunction
animationDelay
animationIterationCount
animationDirection.

Note: Always provisions animationDuration property, otherwise duration to zero, will not play the animation.


 

Internet Explorer 10, Firefox and Opera support animation attributes.

Safari and Chrome support another alternative of the property attribute that WebkitAnimation property.

Note: Internet Explorer 9 and earlier versions do not support animation attributes.


grammar

Returns animation attributes:

object .style.animation

Setting animation properties:

object .style.animation="name duration timingFunction delay iterationCount direction fillMode playState"

Property Value