![]() So obviously there is no way to search for an array item using a condition starting from the right side of the array and this is what these two new methods are bringing to the table. These two methods search starting from the left side and they stop when they find a match. JavaScript currently supports () and () to find the index of an item in the array.Īpart from these, we can use () and () to spot an element in the array based on some condition. At the moment of this writing two brand-new array methods named findLast and findLastIndex are getting closer to official release since they are in stage 3.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |