Function
Rest

_.rest()

_.rest(func, [start=func.length-1])

Creates a function that invokes func with the this binding of the created function and arguments from start and beyond provided as an array.

Note: This method is based on the rest parameter.

Arguments

func (Function): The function to apply a rest parameter to.
[start=func.length-1] (number): The start position of the rest parameter.

Returns

(Function):Returns the new function.

Example