search filter in react code example
Example: react js filter array of on search
use .include array function
{names.filter(name => name.includes('J')).map(filteredName => (
<li>
{filteredName}
</li>
))}
use .include array function
{names.filter(name => name.includes('J')).map(filteredName => (
<li>
{filteredName}
</li>
))}