Skip to main content
Module

x/rambda/source/maxBy-spec.ts

Faster and smaller alternative to Ramda
Go to Latest
File
import {maxBy} from 'rambda'
const compareFn = (x: number) => x % 2 === 0 ? 1 : -1const first = 1const second = 2
describe('R.maxBy', () => { it('happy', () => { const result = maxBy(compareFn, first, second) result // $ExpectType 1 | 2 })})