I am trying to make a simple chrome extension that lets me highlight an element on mouse hover. I am trying to highlight an element (add border shadow around element) but it tends to completely slow the browser to a crawl on sites that seem to have a lot of elements, so I am looking for a more efficient solution.
css file
.highlight {
    -moz-box-shadow: inset 0 0 5px 5px #FF0000;
    -webkit-box-shadow: inset 0 0 5px 5px #FF0000;
    box-shadow: inset 0 0 5px 5px #FF0000;
    transition: box-shadow 0.5s;
    z-index: 99999;
}
js code
$(document).ready(function(){
$('*').on('mouseover',function (e) {
    e.stopPropagation();
    $(e.target).addClass('highlight');
}).on('mouseout', function (e) {
        e.stopPropagation();
        $(e.target).removeClass('highlight');
    });
});
 
     
     
    