SyntaxFix
Write A Post
Hire A Developer
Questions
An equivalent of in_array with underscore is _.indexOf
in_array
underscore
Examples:
_.indexOf([3, 5, 8], 8); // returns 2, the index of 8 _.indexOf([3, 5, 8], 10); // returns -1, not found