Skip to content

boil

Go through a list of items, starting with the first item, and comparing with the second. Keep the one you want then compare that to the next item in the list with the same.

Usage

boil([1, 2, 3, 0], (a, b) => (a > b ? a : b)); // 3

Installation

Terminal window
npx atmx add helper boil