"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
const curry_1 = require("@arrows/composition/curry");
const _findIndex = (testFn, arr) => arr.findIndex(testFn);
/**
 * Functional wrapper for Array.prototype.findIndex
 *
 * Retrieves the index of the first element in the array
 * where predicate is true, and -1 otherwise.
 *
 * @param testFn Test function
 * @param arr Initial array
 * @returns Index of the matching element or -1
 */
const findIndex = curry_1.default(_findIndex);
exports.findIndex = findIndex;
exports.default = findIndex;
