how to add animation with javascript code example
Example 1: js add animation to element
document.getElementById('test').style.animation = 'fading 2s infinite'
Example 2: js add animation to element
var animation = element.animate(keyframes, options);