I am trying to filter some objects in my attempt to understand JS better and I\'m using underscore.js
I come from a C# background and am used to LINQ however undersc
A more concise way to accomplish this would be with underscore's chain() function:
var noMushrooms = _(products).chain() .filter(function (x) { return !x.containsNuts;}) .reject(function(x){ return _(x.ingredients).any(function(y){ return y === "mushrooms"; }); }) .value();