JSFiddle - React, Tailwind, and code Playground
by Eric Howe
HTML
<input type="text" value="pancakes">
<input type="text" value="">
<div id="out"></div>
JavaScript
$('input:eq(1)').val('pancakes');
$('#out').append(
'<p>Selector says: ' +
$('input[value=pancakes]').length
);
$('#out').append(
'<p>Filter says: ' +
$('input').filter(function() { return this.value == 'pancakes' }).length
);