JSFiddle - React, Tailwind, and code Playground

by lollero

HTML

<div>asdasdasdasdasdad <br/><br/> adfasdfsafasfasfd </div>

JavaScript

$('div').on("mouseenter, mouseleave", function( e ) {
    
    var obj = $(this),
        objD = obj.data();
    
    if ( e.type == "mouseenter" ) {
        
    }
    else {

        clearTimeout( objD.wait_in );
        
    }
    
    obj.data( "wait_in", setTimeout( wait, 800 ) );

    function wait() {
    
        alert('');
        
    }
    

});