JSFiddle - React, Tailwind, and code Playground

HTML

<p>Анимация запустится при наведении на блок</p>
<div></div>

<!-- пример сайта know-online.com -->

CSS

div {
    background:green;
    color:#FFF;
    cursor:pointer;
    padding:10px;
    height:100px;
    width:100px;
    transition:background 0.3s, width 1.5s;
}

div:hover {
    background:blue;
    width:200px;
}