What do you all think would be the best (best can be interpreted as most readable or most performant, your choice) way to write a function using the lodash utilities in orde
As of ES6 you can simply use Set so this becomes:
let hasDuplicates = arr => new Set(arr).size != arr.length console.log(hasDuplicates([5,3,2,1,2,1,2,1])) console.log(hasDuplicates([1,2,3,4,5]))
Which somewhat negates the use of lodash in this particular case.