JSFiddle - React, Tailwind, and code Playground

HTML

<div id="container">
    <a href="">aaaa</a>
</div>

CSS

div {
    width: 1000px;
    height: 1000px;
    transition: all 1000ms;
    background-color: green;
}
a:hover{
    color:red;
}

JavaScript

var counter = 0;
f = function() {
    container.style.transform = 'translate(' + 50*(++counter%11) + 'px)';
    setTimeout(function () {
       f();
    }, 2500);
}

f();