JSFiddle - React, Tailwind, and code Playground
by Torwan
HTML
<p>Some Text</p>
CSS
p {
color:black;
}
p:hover, p.hover_effect {
color:red;
}
.hover {
-webkit-user-select: none;
-webkit-touch-callout: none;
}
JavaScript
$(document).ready(function() {
$('p').bind('touchstart touchend', function(e) {
e.preventDefault();
$(this).toggleClass('hover_effect');
});
});