Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

javascript animate elements

document.getElementById("tunnel").animate([
  // keyframes
  { transform: 'translateY(0px)' },
  { transform: 'translateY(-300px)' }
], {
  // timing options
  duration: 1000,
  iterations: Infinity
});
Source by developer.mozilla.org #
 
PREVIOUS NEXT
Tagged: #javascript #animate #elements
ADD COMMENT
Topic
Name
5+2 =