<style>
.square {
width: 100px;
height: 100px;
background-color: red;
}
.square.animated {
animation: backgroud-color-animation 1s;
}
@keyframes backgroud-color-animation {
from {background-color: red;}
to {background-color: yellow;}
}
</style>
<div class="square animated">
</div>
The Web Animations API provides a common language for browsers and developers to describe animations on DOM elements.
Mozilla Developer network
https://github.com/web-animations/web-animations-js
f.strazzullo@e-xtrategy.net
@TheStrazz86
https://github.com/e-xtrategy/web-animations-api-examples