UNPKG

@newdash/newdash

Version:

javascript/typescript utility library

21 lines (20 loc) 406 B
/** * Computes the maximum value of `array`. If `array` is empty or falsey, * `undefined` is returned. * * @since 5.6.0 * @category Math * @param array The array to iterate over. * @returns Returns the maximum value. * @example * * ```js * _.max([4, 2, 8, 6]); * // => 8 * * _.max([]); * // => undefined * ``` */ export declare function max<T>(array: ArrayLike<T>): T; export default max;