Set the name of the CSS @keyframes animation

CSSWeb DevelopmentFront End Technology

Use the animation-name property to set the name of the @keyframes animation. You can try to run the following code to set animation name


Live Demo

<!DOCTYPE html>
         div {
            width: 150px;
            height: 200px;
            position: relative;
            background: red;
            animation-name: myanim;
            animation-duration: 2s;
         @keyframes myanim {
            from {left: 0px; background-color: green;}
            to {left: 100px; background-color: blue;}
Published on 17-May-2018 08:49:47