JSFiddle - React, Tailwind, and code Playground

CSS

.cell {
    height: 25px;
    width: 25px;
    border: solid 1px green;
    float: left;
    background:#000000;
}

JavaScript

$(document).ready(function () {
    for (var i = 0; i <= 128; i++) {
        $('<div />', {
            'class': 'cell',
                'id': 'div' + i
        }).appendTo('body');
    }
});

$('.cell').mouseover(function () {
    $(this).stop(true).fadeTo(200, Math.random());
}).mouseout(function () {
    $(this).fadeTo(200, Math.random());
    $(this).css("background","rgb("+Math.floor(Math.random()*255)+","+Math.floor(Math.random()*255)+","+Math.floor(Math.random()*256)+")")
});