UNPKG

@arrows/array

Version:
15 lines (14 loc) 487 B
declare type _Includes = <T>(element: T, arr: T[]) => boolean; declare type _Includes2 = <T>(element: T) => (arr: T[]) => boolean; declare type Includes = _Includes & _Includes2; /** * Determines whether an array includes a certain element, * returning true or false as appropriate. * * @param element Searched element * @param arr Initial array * @returns True if element exists, false otherwise */ declare const includes: Includes; export { includes }; export default includes;