param arr export function uniqueBy < T > ( arr , callee ) { const result = { } ; for ( const value of arr ) { const hash = callee ( value ) ; if ( ! result [ hash ] ) { result [ hash ] = value ; } } return Object . values ( result ) ; }