0

Any equivalent of this in pure js?

$(".quote-text").animate({ opacity: 0 }, 500, function() { $(this).animate({ opacity: 1 }, 500); $('#text').text(randomQuote.quote); } );

17th May 2020, 10:28 PM
Sajid
Sajid - avatar
1 Réponse
+ 2
You can setTimeout(). That is what jquery uses under the hood. But if it helps there is an experimental feature animate() supported in all major browsers except IE and safari mobile https://developer.mozilla.org/en-US/docs/Web/API/Element/animate
17th May 2020, 11:24 PM
Ore
Ore - avatar