Quicksort in JavaScript using destructuring and spread syntax
Interesting question;

your quicksort is far slower than the regular sort, and is harder to read.
You can find details here: https://jsperf.com/codereview-js-quicksort/15

But in essence this implementation is 90% slower than a regular sort. Using CPU profiling I can tell that most of the time is spent in _.partition which makes sense. Plus you keep creating functions like arr =&gt; quicksort(arr, compareFn) in every call of quicksort which adds up. Finally, that name should really be quickSort; JavaScript functions follow the lowerCamelCase convention.

My counter proposal would simply be:

console.log(
  Array.from('the quick brown fox jumps over the lazy dog').sort(
    (a, b) =&gt; a.charCodeAt(0) - b.charCodeAt(0)
  ).join('')
);


Historically, I have never heard of folks beating the native sort.