JSFiddle - React, Tailwind, and code Playground

JavaScript

var width = $(window).width();
$(window).resize(function () {
    if (
    (width > 769 && $(window).width() < 769) || (width > 300 && $(window).width() < 300) || (width > 1024 && $(window).width() < 1024))

    {
        console.log('reLoad');
    }

});