Optionalfunc: TFunctionThe value to convert to a callback.
Returns the callback.
var users = [
  { 'user': 'barney', 'age': 36 },
  { 'user': 'fred',   'age': 40 }
];
// create custom iteratee shorthands
_.iteratee = _.wrap(_.iteratee, function(callback, func) {
  var p = /^(\S+)\s*([<>])\s*(\S+)$/.exec(func);
  return !p ? callback(func) : function(object) {
    return (p[2] == '>' ? object[p[1]] > p[3] : object[p[1]] < p[3]);
  };
});
_.filter(users, 'age > 36');
// => [{ 'user': 'fred', 'age': 40 }]
Rest...args: any[]
Creates a function that invokes
funcwith the arguments of the created function. Iffuncis a property name the created callback returns the property value for a given element. Iffuncis an object the created callback returnstruefor elements that contain the equivalent object properties, otherwise it returnsfalse.