JSFiddle - React, Tailwind, and code Playground
HTML
<span>good</span>
<span>2</span>
<span>3</span>
<span>1</span>
<span>52</span>
<span>ok23</span>
JavaScript
$('span').each(function(){
if($(this).text().match(/^([1-9])$/))$(this).hide()
});