Latest
function lastIndexOf
import { lastIndexOf } from "https://dotland.deno.dev/x/lodash_es@v0.0.2/src/array.js";

This method is like _.indexOf except that it iterates over elements of array from right to left.

Examples

_.lastIndexOf([1, 2, 1, 2], 2); // => 3

// Search from the fromIndex. _.lastIndexOf([1, 2, 1, 2], 2, 2); // => 1

Parameters

array

The array to inspect.

value

The value to search for.

fromIndex