javascript filter array based on attributes
How to Filter an Array Based on Attributes using JavaScript
Filtering arrays based on attributes is a common task in JavaScript programming. The filter() method is used to create a new array with all elements that pass the test implemented by the provided function. The filter() method is very useful