I want to rotate an element by velocity js but rotateZ
not work but some animations like width, height, opacity and so on work correctly.
This is my simple code:
<style>
#test{
height: 100px;
width: 10px;
background-color: red;
}
</style>
<body>
<div id="test"></div>
<script src="jquery-3.3.1.js"></script>
<script src="velocity.min.js"></script>
<script>
var value = 360; //animate to
var steps = 6; //animation steps per frame (1/60sec.)
var time = (1000 / 60) * (value / steps); //animation time
$('#test').velocity({
rotateZ: "360deg"
}, { delay: 400, duration: 1000, easing: 'linear', loop: true });
</script>
</body>
Is there any special point that I ignore it?!