_.matches

matcher_.matcher(attrs) Alias: matches
Returns a predicate function that will tell you if a passed in object contains all of the key/value properties present in attrs.

1
2
var ready = _.matcher({selected: true, visible: true});
var readyToGoList = _.filter(list, ready);
doc_Underscore
2025-01-10 15:47:30
Comments
Leave a Comment

Please login to continue.