_.drop

Creates a slice of array with n elements dropped from the beginning.

  1. // Underscore/Lodash
  2. _.drop([1, 2, 3]);
  3. // => [2, 3]
  4.  
  5. _.drop([1, 2, 3], 2);
  6. // => [3]
  7.  
  8. // Native
  9. [1, 2, 3].slice(1);
  10. // => [2, 3]
  11.  
  12. [1, 2, 3].slice(2);
  13. // => [3]

Browser Support for Array.prototype.slice()

ChromeEdgeFirefoxIEOperaSafari
1.0 ✔1.0 ✔