x/rambda/source/minBy-spec.ts
12345678910111213import {minBy} from 'rambda'const compareFn = (x: number) => x % 2 === 0 ? 1 : -1const first = 1const second = 2describe('R.minBy', () => { it('happy', () => { const result = minBy(compareFn, first, second) result // $ExpectType 1 | 2 })})