A utility to create comparator functions for the native `Array.sort()`.  Allows for sorting by multiple properties.