JSFiddle - React, Tailwind, and code Playground

HTML

<div target="value">yes</div>
<span class="value">yes</span>

<span class="ghghgh">no</span>

JavaScript

$.expr[":"].attrFilter = function(elem, index, val){
    var len = $(elem.attributes).filter(function () {
        return this.value === val[3];
    }).length;
    if (len > 0) {
        return elem;
    }
};
$('body *:attrFilter("value")').hide();