Function: -max-by
-max-by is a byte-compiled function defined in dash.el.
Signature
(-max-by COMPARATOR LIST)
Documentation
Take a comparison function COMPARATOR and a LIST and return the greatest element of the list by the comparison function.
See also combinator -on which can transform the values before
comparing them.
Source Code
;; Defined in ~/.emacs.d/elpa/dash-20260221.1346/dash.el
(defun -max-by (comparator list)
"Take a comparison function COMPARATOR and a LIST and return
the greatest element of the list by the comparison function.
See also combinator `-on' which can transform the values before
comparing them."
(declare (important-return-value t))
(--reduce (if (funcall comparator it acc) it acc) list))