The Lodash.drop() method is used to drop the elements in a given array.
- Array: It is the original array from which the elements are to be removed.
- Number: It is the number of elements to be removed from the array.
Note: The elements are removed from the index 0 of the array.
Return Value: It returns the sliced array.
Example 2: If elements to be removed from the right side of the array we use _.dropRight() function.
Example 3: If number greater then the size of array is given then it returns the empty array as given in the below given example.
- Underscore.js _.iterators.drop() method
- HTML | Drag and Drop
- Drop shadow for PNG image using CSS
- How to change selected value of a drop-down list using jQuery?
- How to get selected text from a drop-down list using jQuery?
- CSS | drop-shadow() Function
- p5.js | drop() Function
- How to select first element in the drop-down list using jQuery ?
- How to generate a drop down list of timezone using PHP ?
- How to create a drag and drop feature for reordering the images using HTML CSS and jQueryUI ?
- How to create a To-Do list using Drag and Drop in Angular 7 ?
- How to create a group of related options in a drop-down list using HTML ?
- Drag and Drop Files in ElectronJS
- How to define a drop-down list in HTML5 ?
- Lodash _.method() Method
- Lodash _.sneq() Method
- Lodash _.toQuery() Method
- Lodash _.uniqWith() Method
- Lodash _.xorWith() Method
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to email@example.com. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.