JSFiddle - React, Tailwind, and code Playground

by mathheadinclouds

HTML

<div id="test">
    <p id="hello">HELLO</p>
    <p id="no-hello">NO HELLO</p>
</div>

JavaScript

$('#test').click(function() {
    if ($('#hello:hover').length > 0) {
        alert('hello');
    }
});